Hello,
Newbie here. Followed documented steps (https://docs.gitlab.com/runner/install/osx.html ) to install gitlab-runner.
In step 3 you type gitlab-runner register, I do this and get the immediate result:
line 1: syntax error near unexpected token newline' line 1:
<?xml version="1.0" encoding="UTF-8"?>’
I had a second mac, with a clean OS install I did yesterday, followed same three steps and had the same error msg.
Can someone provide direction?
axil
September 20, 2017, 7:34am
2
Hmm, are you sure the Runner is correctly downloaded? Can you run:
file $(which gitlab-runner)
did that, results:
XML 1.0 document text, ASCII text
I’m not sure if my problem is resolved, however, in experimenting I did the following:
Downloaded from https://docs.gitlab.com/runner/install/bleeding-edge.html#download-any-other-tagged-release the file https://gitlab-runner-downloads.s3.amazonaws.com/master/binaries/gitlab-runner-darwin-amd64 .
Did the permission to execute, renamed to gitlab-runner and moved it to the /usr/local/bin
Ran the following cmd ./gitlab-runner register and was given the expected prompt:
Please enter the gitlab-ci coordinator URL (e.g. https://gitlab.com/ ):
SO… Difference is I downloaded a different file, and didn’t use curl… not sure if what I am doing is right…
1 Like
Now I get different error. Got further in the steps. but ends with the following:
ERROR: Registering runner… failed runner=zZFjjbKs status=404 Not Found
PANIC: Failed to register this runner. Perhaps you are having network problems
If I’m having network problems, I’m not aware as all other services/apps/media I consume are working fine.
Runner cannot be downloaded correctly using URL from documentation for Mac. The problem is that url https://gitlab-runner-downloads.s3.amazonaws.com/latest/binaries/gitlab-runner-darwin-amd64 responds:
<?xml version="1.0" encoding="UTF-8"?> <Error><Code>AccessDenied</Code><Message>Access Denied</Message><RequestId>78FF07BECE59008D</RequestId><HostId>XTDYb8KdGwBWZZFjZCQQaqmyT0mCUZVcvLKaEun4ORIZYxfOGNv6B7fr1qrvk+xyOEjRARgJgg8=</HostId></Error>
It should respond with gitlab-runner binary.
This URL is used in documentation “Install on macOS”: https://docs.gitlab.com/runner/install/osx.html
I am dealing with the same issue right now.
Appreciate hearing that, still haven’t found a solution and going a little bonkers trying to figure it out. Glad to hear someone else is having this.
If I come up with a solution, and it’s before you do. I’ll post it here.
1 Like
so not sure if this is a solution or not. but I didn’t bother using curl to download the latest version as the instructions indicate. Instead I used the bleeding edge link and found a tag for v10.0.0-rc.1. I swapped master with the tag in the url (for instance on the mac: https://gitlab-runner-downloads.s3.amazonaws.com/v10.0.0-rc.1/binaries/gitlab-runner-darwin-amd64 ).
Once downloaded I set the permission and changed the name to gitlab-runner and moved the file to /usr/local/bin
It runs fine for me now after I fixed one other error on my part. When it asked for the gitlab-ci coordinator URL I gave the full path vs the root (example https://somename.com/ vs what I was doing https://somename.com/someterm ).
Once I fixed that, the runner registered as expected.
Hope that helps.
1 Like
Awesome fix man! It works for me now, when using your workaround. They need to update those docs or something
Also experiencing this issue.
Worked for me as well. Thank you for the tip!
I had to download the .deb
package and just installed it with gdebi & everything is kosher now.
I had initially tried installing with apt
, so be sure if you did this to apt remove gitlab-runner
first.