gcloud:找不到命令
我得到了以下错误:
运行管道上的管道失败管道gitlab 将这工作部署到生产没有成功。
Running with gitlab-runner 15.1.0 (76984217)
on ci 3wNvyH89
Preparing the "shell" executor
00:00
Using Shell executor...
Preparing environment
00:00
Running on localhost.localdomain...
Getting source from Git repository
00:00
Fetching changes with git depth set to 20...
Reinitialized existing Git repository in /home/gitlab-runner/builds/3wNvyH89/0/root/yogesh1/.git/
Checking out 668d7d24 as main...
Skipping Git submodules setup
Executing "step_script" stage of the job script
00:00
$ echo $SERVICE_ACCOUNT > /tmp/$CI_PIPELINE_ID.json
$ gcloud auth activate-service-account --key-file /tmp/$CI_PIPELINE_ID.json
bash: line 125: gcloud: command not found
Running after_script
00:00
Running after script...
$ rm /tmp/$CI_PIPELINE_ID.json
ERROR: Job failed: exit status 1
I got the followwing error:
error failed pipeline on run pipeline gitlab
The deployment of this job to Production did not succeed.
Running with gitlab-runner 15.1.0 (76984217)
on ci 3wNvyH89
Preparing the "shell" executor
00:00
Using Shell executor...
Preparing environment
00:00
Running on localhost.localdomain...
Getting source from Git repository
00:00
Fetching changes with git depth set to 20...
Reinitialized existing Git repository in /home/gitlab-runner/builds/3wNvyH89/0/root/yogesh1/.git/
Checking out 668d7d24 as main...
Skipping Git submodules setup
Executing "step_script" stage of the job script
00:00
$ echo $SERVICE_ACCOUNT > /tmp/$CI_PIPELINE_ID.json
$ gcloud auth activate-service-account --key-file /tmp/$CI_PIPELINE_ID.json
bash: line 125: gcloud: command not found
Running after_script
00:00
Running after script...
$ rm /tmp/$CI_PIPELINE_ID.json
ERROR: Job failed: exit status 1
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这取决于您在
gitlab-ci.yml
中使用的图像。例如,在文章中,“ 如何为Google Cloud App Engine设置Gitlab CI管道?”来自 nofollow noreferrer“>他正在使用:
这意味着
gcloud
已经安装在$ path
中。It depends on the image you are using in your
gitlab-ci.yml
.For instance, in the article "How to Setup Gitlab CI Pipeline For Google Cloud App Engine?" from Tapendra Dev, he is using:
Which means
gcloud
is already installed and in the$PATH
.