错误:作业失败:构建目录需要是绝对路径

Vas*_*ved 2 gitlab-ci-runner

  • 在 Windows 上安装 Gitlab runner
  • 挂号的
  • 使用 test gitlab ci yaml 配置文件配置了一个测试 repo
  • CI/CD 管道显示错误
ERROR: Job failed: build directory needs to be an absolute path
Run Code Online (Sandbox Code Playgroud)

这是.gitlab-ci.yml

image: busybox:latest

before_script:
  - echo "Before script section"
  - echo "For example you might run an update here or install a build dependency"
  - echo "Or perhaps you might print out some debugging details"

after_script:
  - echo "After script section"
  - echo "For example you might do some cleanup here"

build1:
  stage: build
  script:
    - echo "Do your build here"

test1:
  stage: test
  script: 
    - echo "Do a test here"
    - echo "For example run a test suite"

test2:
  stage: test
  script: 
    - echo "Do another parallel test here"
    - echo "For example run a lint test"

deploy1:
  stage: deploy
  script:
    - echo "Do your deploy here"
Run Code Online (Sandbox Code Playgroud)

Rom*_*ter 6

我不知道你有什么类型的跑步者,就我而言,我对 docker-ssh 跑步者有同样的问题。我的解决方法是在 config.toml 中指定 build_dir

[[runners]]
  name = "jira-ssh-runner"
  executor = "docker-ssh"
  builds_dir = "/home/gitlab-runner/build"
Run Code Online (Sandbox Code Playgroud)