首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >错误:生成步骤0 "gcr.io/cloud-builders/docker“失败:退出状态1

错误:生成步骤0 "gcr.io/cloud-builders/docker“失败:退出状态1
EN

Stack Overflow用户
提问于 2019-04-22 17:40:44
回答 3查看 7K关注 0票数 3

我试图使用bitbucket管道在google云桶中部署我的第一个应用程序,但是我在google云控制台中得到了下面的错误。

代码语言:javascript
复制
ERROR: build step 0 "gcr.io/cloud-builders/docker" failed: exit status 1
ERROR
The command '/bin/sh -c yarn install --production || ((if [ -f yarn-error.log ]; then cat yarn-error.log; fi) && false)' returned a non-zero code: 1
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
error Found incompatible module
error acp-web@1.0.0: The engine "node" is incompatible with this module. Expected version "9.11.1". Got "9.11.2"
[1/5] Validating package.json...
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json.
yarn install v1.15.2
---> Running in c25c801a41d0
Step 5/6 : RUN yarn install --production || ((if [ -f yarn-error.log ]; then cat yarn-error.log; fi) && false)
---> 9a31a847bb75
[...]

基本上,我有一个React应用程序,需要在google云中部署,我已经成功地解决了所有的but,但是现在我还不知道问题出在哪里。

bitbucket-pipeline.yml

代码语言:javascript
复制
image: node:10.15.1

pipelines:
  default:
    - step:
        name: Build and Test
        script:
          - npm install
          - npm test
    - step:
        name: Deploy
        script:
          - pipe: atlassian/google-app-engine-deploy:0.2.1
            variables:
              KEY_FILE: $KEY_FILE
              PROJECT: '[project-name] is here'

app.yaml

代码语言:javascript
复制
env: flex
runtime: custom
api_version: 1
threadsafe: true
handlers:
- url: /(.*\.(html|css|js|png|jpg|woff|json))
  static_files: dist/\1
  upload: dist/(.*\.(html|css|js|png|jpg|woff|json))
- url: /.*
  static_files: dist/index.html
  upload: dist/index.html
- url: /
  static_dir: build
skip_files:
- node_modules/
- ^\.git/.*
- ^(.*/)?#.*#$
- ^(.*/)?.*~$
- ^(.*/)?.*\.py[co]$
- ^(.*/)?.*/RCS/.*$
- ^(.*/)?\..*$
- ^(.*/)?.*\.bak$

我只想把这个应用部署到google云应用引擎中。

EN

回答 3

Stack Overflow用户

发布于 2019-04-22 21:40:51

它似乎使用了不正确的node.js版本,如下所示:

代码语言:javascript
复制
error acp-web@1.0.0: The engine "node" is incompatible with this module. Expected version "9.11.1". Got "9.11.2"

不过,您将在管道中指定10.15.1。你能确保正确的版本被应用于你的项目吗?

票数 2
EN

Stack Overflow用户

发布于 2020-10-15 17:21:36

在我的例子中,有一些人在同一个项目中使用纱线和npm。一旦我进入回购和运行npm安装,它更新了几个包,然后码头工作流程是好的。

票数 1
EN

Stack Overflow用户

发布于 2020-04-07 23:25:30

在app.yaml文件中,您需要提到:

代码语言:javascript
复制
runtime: nodejs
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/55798565

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档