1

I am using Jenkins to trigger some stuff on gcloud and I need to be able to pass a parameter from the Build with parameters menu to the gcloud command that is being triggered. So let's say my gcloud command is:

gcloud firebase test android run .... --device model=shamu I'd like the passed device model to be a variable. So I tried something like DEVICE_MODEL as parametrized string and stuff like this:

gcloud firebase test android run .... --device model=${DEVICE_MODEL}
gcloud firebase test android run .... --device model=$"DEVICE_MODEL"
gcloud firebase test android run .... --device model=${"DEVICE_MODEL"}

But nothing works.. Any ideas what am I doing wrong?

Pavel Zagalsky
  • 1,620
  • 7
  • 22
  • 52

1 Answers1

2

Solved this by using gcloud firebase test android run .... --device model=${DEVICE_MODEL} in Execute Shell as a Build Step instead of a dedicated gcloud build step

Frank van Puffelen
  • 565,676
  • 79
  • 828
  • 807
Pavel Zagalsky
  • 1,620
  • 7
  • 22
  • 52