ci: fix rook cluster version fetching

As part of https://github.com/ceph/ceph-csi/pull/1237/ there was
a patching enabled for the ceph cluster deployed, however due to
an error in the version fetching logic, the patching was not applied

Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
This commit is contained in:
Humble Chirammal 2020-07-23 14:18:06 +05:30 committed by mergify[bot]
parent 92884f56f4
commit 9e0589cf12

View File

@ -7,7 +7,7 @@ ROOK_BLOCK_POOL_NAME=${ROOK_BLOCK_POOL_NAME:-"newrbdpool"}
ROOK_CEPH_CLUSTER_VERSION="v14.2.10"
rook_version() {
echo "${ROOK_VERSION#?v}" | cut -d'.' -f"${1}"
echo "${ROOK_VERSION#v}" | cut -d'.' -f"${1}"
}
function deploy_rook() {
@ -21,8 +21,8 @@ function deploy_rook() {
# upgrade ceph cluster version to 14.2.10 to support CephFS snapshot functionalities.
TEMP_DIR="$(mktemp -d)"
curl -o "${TEMP_DIR}"/cluster-test.yaml "${ROOK_URL}/cluster-test.yaml"
sed -i "s|image.*|${ROOK_CEPH_CLUSTER_VERSION_IMAGE_PATH}|g" cluster-test.yaml
cat cluster-test.yaml
sed -i "s|image.*|${ROOK_CEPH_CLUSTER_VERSION_IMAGE_PATH}|g" "${TEMP_DIR}"/cluster-test.yaml
cat "${TEMP_DIR}"/cluster-test.yaml
kubectl create -f "${TEMP_DIR}/cluster-test.yaml"
rm -rf "${TEMP_DIR}"
else