ERROR: Job failed: build directory needs to be an absolute path
这里是.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"
答案 0 :(得分:0)
我不知道您使用哪种类型的运行程序,就我而言,我在docker-ssh运行程序中也遇到了同样的问题。对我来说,一种解决方法是在config.toml中指定build_dir
[[runners]]
name = "jira-ssh-runner"
executor = "docker-ssh"
builds_dir = "/home/gitlab-runner/build"
答案 1 :(得分:0)
在Windows上,它在路径中使用双斜杠
[[runners]]
name = "development-server-runner"
url = "https://*****.com"
token = "n****tq"
builds_dir = "E:\\00-gitlab-build"
executor = "shell"
shell = "powershell"
[runners.custom_build_dir]
enabled = true
[runners.cache]
[runners.cache.s3]
[runners.cache.gcs]