User ID for build agent - how to specify that?

I’ve three build-agent machines. Two MacMinis and a Linux box. On the two MacMini’s the buildkite agent is running as the human that set it up. On the Linux box it’s running as user buildkite-agent. I’d like to change that to the human (me; ‘paul’) who setup the box. How do I do that?

What version of Linux? Is it running systemd? You will most likely need to create a custom systemd service file (if you haven’t already) and set the user there.

For debian based systems it would be cp /lib/systemd/system/buildkite-agent.service /etc/systemd/system/buildkite-agent.service and then update the User=buildkite-agent line in /etc/systemd/system/buildkite-agent.service. For redhat based I think it’s /usr/lib/systemd/system/buildkite-agent.service you need to copy.

Kernel 5.2.0-15-generic : UBuntu 19.10, 64bit.

/etc/systemd/system/buildkite-agent.service already has line User=buildkite-agent - what are you saying I should update it to? Doh, to to the human account I’m talking about in the OP.

Yep :grinning: did you get it to work?