我尝试在 Atlassian/Bitbucket 社区支持中发帖,但我的帖子没有发到那里。他们甚至没有显示为待处理/需要审核/任何。
我不明白为什么在设置过程中某个步骤失败了。我正在运行一个自托管的运行器(并为运行器容器提供 6 GB 的内存,所以我不认为这是一个 OOM 错误)并且我正在测试一个相当简单的管道:
第 1 步 - 根据需要进行凹凸版本 - 超轻量级 - 通过良好。
第 2 步 - 将 go 可执行文件构建到 Docker 映像中,发布到 gcr.io - 仍然非常轻量级 - 在设置过程中失败
这是我的 bitbucket-pipelines.yml:
image:
name: gcr.io/novo00/bitbucket-pipelines:latest
username: _json_key
password: '$NOVO_GCR_IO_JSON_KEY'
pipelines:
branches:
master:
- step:
runs-on:
- self.hosted
script:
- build/bitbucket_pipelines/version.sh
- step:
runs-on:
- self.hosted
script:
- build/bitbucket_pipelines/build.sh
services:
- docker
这是管道仪表板中“构建设置”的输出:
+ umask 000
+ GIT_LFS_SKIP_SMUDGE=1 retry 6 git clone --branch="master" --depth 50 https://x-token-auth:$REPOSITORY_OAUTH_ACCESS_TOKEN@bitbucket.org/$BITBUCKET_REPO_FULL_NAME.git $BUILD_DIRCloning into '/opt/atlassian/pipelines/agent/build'...
之后什么都没有,然后进入“构建拆卸”。
这是我的跑步者标准输出的片段:
[2021-07-27 21:52:30,706] Starting container.
[2021-07-27 21:52:30,739] Adding container log: /var/lib/docker/containers/02152994b7d0485fa65a5dd8a4dd5254ea1c7a41b9b00f98ed5478245e3255da/02152994b7d0485fa65a5dd8a4dd5254ea1c7a41b9b00f98ed5478245e3255da-json.log
[2021-07-27 21:52:30,740] Waiting on container to exit.
[2021-07-27 21:52:30,741] Creating exec into container.
[2021-07-27 21:52:30,749] Starting exec into container and waiting for exec to exit.
[2021-07-27 21:52:30,949] Adding container log: /var/lib/docker/containers/1467fcbb959c9f17eacd2bc04967e4fe8042ba1fbc3bcb0a345d6da6db1717d0/1467fcbb959c9f17eacd2bc04967e4fe8042ba1fbc3bcb0a345d6da6db1717d0-json.log
[2021-07-27 21:52:30,949] Waiting on container to exit.
[2021-07-27 21:52:30,981] Adding container log: /var/lib/docker/containers/a62ece4849a5ee784f4f483d58eb87c3684f52ebca35308e6d485e014a17ac99/a62ece4849a5ee784f4f483d58eb87c3684f52ebca35308e6d485e014a17ac99-json.log
[2021-07-27 21:52:30,981] Waiting on container to exit.
[2021-07-27 21:52:31,051] Container has state (exitCode: Some(4), OOMKilled Some(false))
[2021-07-27 21:52:31,054] Removing container build
[2021-07-27 21:52:31,065] Not uploading caches. (numberOfCaches: 0, resultOrError: FAILED)
[2021-07-27 21:52:31,066] Not uploading artifacts. (numberOfArtifacts: 0, resultOrError: FAILED)
[2021-07-27 21:52:31,066] Updating step progress to PARSING_TEST_RESULTS.
[2021-07-27 21:52:31,401] Test report processing complete.
[2021-07-27 21:52:31,401] Removing container clone
[2021-07-27 21:52:31,562] Removing container clone
[2021-07-27 21:52:31,565] Removing container build
[2021-07-27 21:52:31,568] Removing container system-docker
[2021-07-27 21:52:31,583] Removing container system-auth-proxy
[2021-07-27 21:52:31,698] Removing container pause
[2021-07-27 21:52:31,749] Appending log line to log: {bc88f95e-9f7b-425a-adaf-e3060f3a53ee}.
[2021-07-27 21:52:31,754] Appending log line to main log.
[2021-07-27 21:52:31,861] Updating step progress to COMPLETING_LOGS.
[2021-07-27 21:52:31,972] Appending log line to log: {71708781-63f3-46de-8042-730f079fe9d6}.
[2021-07-27 21:52:32,009] Shutting down log uploader.
[2021-07-27 21:52:32,224] Tearing down directories.
[2021-07-27 21:52:32,227] Cancelling timeout
[2021-07-27 21:52:32,228] Completing step with result Result{status=FAILED, error=None}.
注意 Container has state (exitCode: Some(4), OOMKilled Some(false))
有什么帮助吗?我可以提供任何其他数据吗?我尝试查看输出中提到的一些日志,但它们要么不再存在,要么没有包含太多有用的信息。
更新:从步骤 2 中删除 services: - docker
修复了当前问题,但我需要该步骤可用的 docker 服务。立即寻找修复方法。