Name: agent
Owner: Buildkite
Description: The Buildkite Agent is an open-source toolkit written in Golang for securely running build jobs on any device or network
Created: 2014-01-29 14:31:28.0
Updated: 2018-01-19 00:50:04.0
Pushed: 2018-01-19 04:09:33.0
Homepage: https://buildkite.com/
Size: 20392
Language: Go
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
Note: This is the 3.0 development branch of the buildkite-agent, and may not contain files or code in the current stable release. To see code or submit PRs for stable agent versions, please use the corresponding maintenance branch: 2.6.x.
The buildkite-agent is a small, reliable, and cross-platform build runner that makes it easy to run automated builds on your own infrastructure. It?s main responsibilities are polling buildkite.com for work, running build jobs, reporting back the status code and output log of the job, and uploading the job's artifacts.
Full documentation is available at buildkite.com/docs/agent
ildkite-agent --help
e:
ildkite-agent <command> [arguments...]
lable commands are:
art Starts a Buildkite agent
tifact Upload/download artifacts from Buildkite jobs
ta-data Get/set data from Buildkite jobs
peline Make changes to the pipeline of the currently running build
otstrap Run a Buildkite job locally
lp, h Shows a list of commands or help for one command
"buildkite-agent <command> --help" for more information about a command.
The agents page on Buildkite has personalised instructions for installing the agent with Ubuntu (via apt), Debian (via apt), macOS (via homebrew), Windows and Linux. You can also run the agent via Docker.
To start an agent all you need is your agent token, which you can find on your Agents page within Buildkite.
dkite-agent start --token
These instructions assume you are running a recent macOS, but could easily be adapted to Linux and Windows.
er-compose run agent bash
@d854f845511a:/go/src/github.com/buildkite/agent# go run main.go start --token xxx --debug
ke sure you have go installed.
install go
tup your GOPATH
rt GOPATH="$HOME/go"
rt PATH="$HOME/go/bin:$PATH"
eckout the code
et github.com/buildkite/agent
$HOME/go/src/github.com/buildkite/agent"
To test the commands locally:
un main.go start --debug --token "abc123"
This requires either Virtualbox (free) or VMWare Fusion + Vagrant VMWare Fusion plugin (paid).
It assumes that you have Docker for Mac or similar installed. The following commands are run on your local machine. Expect things to take a long time, the vagrant box is 10GB and the docker base image is 3.4GB.
ant up
$(docker-machine env windows-2016)
er-compose -f docker-compose.windows.yml run agent cmd
opath\src\github.com\buildkite\agent> go run main.go start --token xxx --debug
We're using govendor to manage our Go dependencies. Install it with:
et github.com/kardianos/govendor
If you introduce a new package, just add the import to your source file and run:
ndor fetch +missing
Or explicitly fetch it with a version using:
ndor fetch github.com/buildkite/go-buildkite@v2.0.0
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)Copyright (c) 2014-2017 Buildkite Pty Ltd. See LICENSE for details.