【发布时间】:2018-07-23 01:27:17
【问题描述】:
我有一个处理两个项目的 AWS CodeBuild,在构建过程中,源代码将被构建并捆绑在 zip 文件中并放置在 bundles/* 中。
以下是目录树的样子,其中 bundles 包含要部署的生成的 zip 文件:
它使用以下buildspec.yml:
version: 0.2
phases:
install:
commands:
- ./manager.sh install
build:
commands:
- ./manager.sh build
- ./manager.sh package
- ./manager.sh test
- ./manager.sh test:functional
- ./manager.sh test:deploy
post_build:
commands:
- ls -l bundles # I see the artifacts on the console using this
artifacts:
files:
- 'bundles/*'
这会返回Skipping invalid artifact path [edited] not a valid identifier .(应该是捆绑包)
我尝试了以下多种组合:
这个返回Skipping invalid artifact path [edited] not a valid identifier bundles
artifacts:
base-directory: bundles
files:
- '**/*'
或者这个Skipping invalid artifact path [edited] not a valid identifier .
artifacts:
files:
- bundles
这是完整的错误:
[Container] 2018/02/12 19:13:05 Expanding /codebuild/output/tmp/env.sh: line 69: export: `npm_config_unsafe-perm': not a valid identifier
.
[Container] 2018/02/12 19:13:05 Skipping invalid artifact path /codebuild/output/tmp/env.sh: line 69: export: `npm_config_unsafe-perm': not a valid identifier
.
[Container] 2018/02/12 19:13:05 Phase complete: UPLOAD_ARTIFACTS Success: false
[Container] 2018/02/12 19:13:05 Phase context status code: CLIENT_ERROR Message: No matching base directory path found for /codebuild/output/tmp/env.sh: line 69: export: `npm_config_unsafe-perm': not a valid identifier
.
[Container] 2018/02/12 19:13:07 Runtime error (*errors.errorString: No matching base directory path found for /codebuild/output/tmp/env.sh: line 69: export: `npm_config_unsafe-perm': not a valid identifier
.)
可以是我的docker container吗?
【问题讨论】:
标签: amazon-web-services yaml aws-codebuild