I see that my runner is trying to clone the repository from localhost:8081
.
The problem is that my repository is on the gitlab server which is not localhost:8081
.
How do I tell my gitlab to tell to the runner that he has another address (like 10.29.39.29:43823
?)
GitLab should send the repo URL to the Runner, so if GitLab is sending localhost:8081
while it's really on 10.29.39.29:43823
then the GitLab instance is what's misconfigured, not the Runner.
According to the Documentation you can set the external URL by adding/editing etc/gitlab/gitlab.rb
with external_url "http://gitlab.example.com"
, in your case external_url 10.29.39.29:43823
. After that, run sudo gitlab-ctl reconfigure
and the Runner should work.
If you're not using Omnibus (and you definitely should be, since this kind of thing is a decent bit more complicated), this won't work.
Assuming that doesn't work, are you hosting it yourself? What version of GitLab and GitLab Runner are you using?
You may also change the runner's config.toml:
[[runners]]
clone_url = "10.29.39.29:43823"
https://docs.gitlab.com/runner/configuration/advanced-configuration.html#how-clone_url-works
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With