我正在使用Jenkins触发gcloud上的某些内容,我需要能够将Build with parameters菜单中的参数传递给要触发的gcloud命令. 因此,假设我的gcloud命令为:
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测试android运行....--device model = shamu 我希望传递的设备模型是一个变量. 所以我尝试了类似的东西 DEVICE_MODEL作为参数化字符串和类似这样的东西:
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?
推荐答案通过在Execute Shell中将gcloud firebase test android run .... --device model=${DEVICE_MODEL}用作构建步骤而不是专用的gcloud构建步骤来解决了此问题
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
更多推荐
通过Jenkins将参数传递给gcloud应用
发布评论