gpt4 book ai didi

timeout - GitLab CI 管道阶段超时

转载 作者:行者123 更新时间:2023-12-03 11:12:38 24 4
gpt4 key购买 nike

我正在使用自托管 GitLab CI server (社区版 v8.9.5)和 gitlab-ci-multi-runner 1.2.0 构建项目。我的一个管道阶段(测试)需要一段时间才能运行,我得到以下 erm:

ERROR: Build failed: execution took longer than 3600 seconds


我在哪里放置此超时的覆盖?我可以将它仅应用于测试管道阶段吗?

最佳答案

在旧版本中,您可以在“项目设置 -> CI/CD 管道 -> 超时”或“项目设置 -> 构建 -> 超时”中设置全局超时。
从 12.3 版开始,您可以使用 timeout 在 CI .yml 文件中设置每个阶段的超时时间:

timeout allows you to configure a timeout for a specific job. For example:

build:
script: build.sh
timeout: 3 hours 30 minutes

test:
script: rspec
timeout: 3h 30m

The job-level timeout can exceed the project-level timeout but can’t exceed the Runner-specific timeout.

关于timeout - GitLab CI 管道阶段超时,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38403681/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com