首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Bitbucket自托管运行程序在步骤设置过程中失败

Bitbucket自托管运行程序在步骤设置过程中失败
EN

Stack Overflow用户
提问于 2021-07-28 15:33:40
回答 1查看 1.4K关注 0票数 1

我试着在aren/Bitbucket社区支持中发布这篇文章,但我的帖子并没有在那里发布。他们甚至没有出现作为待定/需要适度/其他什么。

我不明白为什么一个步骤在安装过程中失败。我正在运行一个自我托管的运行程序(并将6GB的内存分配给运行程序容器,因此我不认为这是OOM错误),我正在测试一个相当简单的管道:

第一步-碰撞版视需要-超级轻量级-通过罚款。

步骤2-将go可执行文件生成到Docker映像中,发布到gcr.io (仍然相当轻量级)在安装过程中失败

这里是我的bitbucket-管道. Here:

代码语言:javascript
复制
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

下面是管道仪表板中“构建安装程序”的输出:

代码语言:javascript
复制
+ 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'...

在那之后什么都没有,然后进入“构建拆卸”。

下面是我的跑步者标准的一个片段:

代码语言:javascript
复制
[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修复了当前问题,但我需要步骤可用的对接服务。现在想找个解决办法。

EN

回答 1

Stack Overflow用户

发布于 2022-01-06 09:02:20

我在使用自我托管的跑步者时遇到了一些问题。经过两天的网络挖掘,我知道:

  1. 在大多数情况下,自我托管的码头管理员工作得很好。
  2. 除了码头工人的案子外,他们都做得很好。如果您需要在管道中运行docker,则应该使用选定的Linux类型和版本。我测试了Debian 9,Debian 11,Ubuntu20LTS,CentOS8,CentOS 7.9.2009。只有最后一个才能正常工作。
  3. 即使您使用兼容的Linux安装,您也可能在您的坞构建过程中遇到问题。不同的问题。多亏了这个职位,我把它修好了。
  4. 如果使用WSL2和DockerDesktop,就不会有来自容器的任何日志。这是由于DD中的另一个日志文件位置(它们在执行WSL机器时不可用)。如果您需要日志(即用于调试)并使用Windows,只需在Linux中安装VirtualBox、安装停靠程序并在其中附加运行程序即可。
票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/68563309

复制
相关文章

相似问题

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