0

I want to run a trigger by passing some substitution values by using gcloud command. Here is my command:

gcloud beta builds triggers run my-service --branch=test-deploy-of-history --project=dev-project --substitutions=_SERVICE_NAME=flow

After entering the command, I am getting this error message:

ERROR: (gcloud.beta.builds.triggers.run) unrecognized arguments: --substitutions=_SERVICE_NAME=flow

Is there any way to pass substitutions values while using this command ?

  • can you try updating the beta component with `gcloud components update`.Refer this [document](https://cloud.google.com/sdk/gcloud/reference/components/update) – Sathi Aiswarya Jul 11 '23 at 10:19

1 Answers1

2

As of version 433.0.0 of the Google Cloud SDK (released on May 31, 2023), there have been some breaking changes to the gcloud beta builds triggers run command.Refer to this documentation for more information

Cloud Build

  • Added flag to specify substitutions in gcloud builds triggers run.
  • Modified --branch, --tag, --sha flags to be optional in gcloud builds triggers run command.

You can try updating the beta component; it will update all of your installed components to the latest version.you can refer to this document

gcloud components update
Sathi Aiswarya
  • 2,068
  • 2
  • 11
  • Thank you very much. It worked for me now. I tried gcloud components update and it worked for me. I was missing that portion as my local versions were not up to date. – Md. Omar Hasan Jul 16 '23 at 21:01