Skip to content

Commit

Permalink
Merge pull request #993 from karelyatin/operator_status_rabbit
Browse files Browse the repository at this point in the history
Fix issue with rabbitmq operator status check
  • Loading branch information
openshift-merge-bot[bot] authored Dec 23, 2024
2 parents 17f0544 + cde79d2 commit 209e1db
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion scripts/get-operator-status.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,13 @@ if [ -z "$OPERATOR_NAME" ]; then
echo "Please set OPERATOR_NAME"; exit 1
fi

REPLICAS=$(oc get -n "${OPERATOR_NAMESPACE}" deployment ${OPERATOR_NAME}-operator-controller-manager -o json | jq -e '.status.availableReplicas')
if [ "$OPERATOR_NAME" = "rabbitmq-cluster" ]; then
DEPL_NAME="rabbitmq-cluster-operator"
else
DEPL_NAME=${OPERATOR_NAME}-operator-controller-manager
fi

REPLICAS=$(oc get -n "${OPERATOR_NAMESPACE}" deployment ${DEPL_NAME} -o json | jq -e '.status.availableReplicas')
if [ "$REPLICAS" != "1" ]; then
exit 1
fi
Expand Down

0 comments on commit 209e1db

Please sign in to comment.