Update apps/demo-nginx/Jenkinsfile
This commit is contained in:
6
apps/demo-nginx/Jenkinsfile
vendored
6
apps/demo-nginx/Jenkinsfile
vendored
@@ -474,7 +474,6 @@ EOF
|
||||
# 2. Verify pod images (source of truth)
|
||||
echo ""
|
||||
echo "2. Checking running pod images..."
|
||||
|
||||
POD_IMAGES=$(kubectl get pods -n "${NAMESPACE}" -l app="${APP_NAME}" \
|
||||
-o jsonpath='{.items[*].spec.containers[0].image}')
|
||||
|
||||
@@ -482,10 +481,9 @@ EOF
|
||||
echo " Expected tag: ${IMAGE_TAG}"
|
||||
|
||||
if [[ "${POD_IMAGES}" != *"${IMAGE_TAG}"* ]]; then
|
||||
echo " ❌ FAILED: Pods are running wrong image!"
|
||||
exit 1
|
||||
echo " ❌ FAILED: Pods are running wrong image!"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo " ✅ All pods are running expected image"
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user