While deploying to GCP using Terraform and in our YAML file we have the following section
# Deploy to Cloud Run
- id: 'deploy'
name: 'gcr.io/cloud-builders/gcloud'
waitFor: ['build-image','push-image']
entrypoint: bash
args:
- '-c'
- |
gcloud beta run services update $_SERVICE_NAME \
'--platform=$_PLATFORM' \
'--image=$_IMAGE_NAME' \
--labels=managed-by=gcp-cloud-build-deploy-cloud-run,commit-sha=$COMMIT_SHA,gcb-build-id=$BUILD_ID \
'--region=$_GCP_REGION' \
--tag '$_REVISION' \
We set WaitFor
for all previous dependencies for testing. We are getting this error:
Starting Step #3 - "deploy"
Step #3 - "deploy": Already have image (with digest): gcr.io/cloud-builders/gcloud
Step #3 - "deploy": Deploying...
Step #3 - "deploy": Creating Revision......interrupted
Step #3 - "deploy": Deployment failed
Step #3 - "deploy": ERROR: (gcloud.beta.run.services.update) Revision my-service-ui-00007-doq is not ready.
Finished Step #3 - "deploy"
ERROR
ERROR: build step 3 "gcr.io/cloud-builders/gcloud" failed: step exited with non-zero status: 1
We have tried playing around with the command line and that is showing the same error. We tried several times, so this is not a random error. Any idea what could cause this? Or any clue how we could investigate it?