Note: This is the development branch of the buildkite-agent, and may not contain files or code in the current stable release.
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
$ buildkite-agent --help
Usage:
buildkite-agent <command> [arguments...]
Available commands are:
start Starts a Buildkite agent
artifact Upload/download artifacts from Buildkite jobs
meta-data Get/set data from Buildkite jobs
pipeline Make changes to the pipeline of the currently running build
bootstrap Run a Buildkite job locally
help, h Shows a list of commands or help for one command
Use "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.
buildkite-agent start --tokenThese instructions assume you are running a recent macOS, but could easily be adapted to Linux and Windows.
# Make sure you have go 1.10+ installed.
brew install go
# Setup your GOPATH
export GOPATH="$HOME/go"
export PATH="$HOME/go/bin:$PATH"
# Checkout the code
go get github.com/buildkite/agent
cd "$HOME/go/src/github.com/buildkite/agent"
# Start the agent
go run main.go start --debug --token "abc123"We're using govendor to manage our Go dependencies. Install it with:
go get github.com/kardianos/govendorIf you introduce a new package, just add the import to your source file and run:
govendor fetch +missingOr explicitly fetch it with a version using:
govendor fetch github.com/buildkite/[email protected]- Fork it
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Add some feature') - Push to the branch (
git push origin my-new-feature) - Create new Pull Request
Many thanks to our fine contributors! @adill, @airhorns, @alexjurkiewicz, @bendrucker, @bradfeehan, @byroot, @cab, @caiofbpa, @colinrymer, @cysp, @daveoflynn, @daveoxley, @daveslutzkin, @davidk-zenefits, @DazWorrall, @dch, @deoxxa, @dgoodlad, @donpinkster, @essen, @grosskur, @jgavris, @joelmoss, @jules2689, @julianwa, @kouky, @marius92mc, @mirdhyn, @mousavian, @nikyoudale, @pda, @rprieto, @samritchie, @silarsis, @skevy, @stefanmb, @tekacs, @theojulienne, @tommeier, @underscorediscovery, and @wolfeidau.
Copyright (c) 2014-2017 Buildkite Pty Ltd. See LICENSE for details.