1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-25 03:17:13 +00:00
nixpkgs/pkgs/development/tools/continuous-integration/buildkite-agent/default.nix

44 lines
1.5 KiB
Nix
Raw Normal View History

{ stdenv, fetchurl, makeWrapper, coreutils, git, openssh, bash, gnused, gnugrep }:
stdenv.mkDerivation rec {
2016-05-31 15:22:15 +01:00
version = "2.1.13";
name = "buildkite-agent-${version}";
dontBuild = true;
src = fetchurl {
url = "https://github.com/buildkite/agent/releases/download/v${version}/buildkite-agent-linux-386-${version}.tar.gz";
2016-05-31 15:22:15 +01:00
sha256 = "bd40c2ba37b3b54b875241a32b62190a4cf4c15e2513c573f1626a3ca35c8657";
};
nativeBuildInputs = [ makeWrapper ];
sourceRoot = ".";
installPhase = ''
install -Dt "$out/bin/" buildkite-agent
mkdir -p $out/share
mv hooks bootstrap.sh $out/share/
'';
postFixup = ''
substituteInPlace $out/share/bootstrap.sh \
--replace "#!/bin/bash" "#!$(type -P bash)"
wrapProgram $out/bin/buildkite-agent \
2016-08-22 23:06:51 +01:00
--set PATH '"${stdenv.lib.makeBinPath [ openssh git coreutils gnused gnugrep ]}:$PATH"'
'';
meta = {
description = "Build runner for buildkite.com";
longDescription = ''
The buildkite-agent is a small, reliable, and cross-platform build runner
that makes it easy to run automated builds on your own infrastructure.
Its 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.
'';
homepage = https://buildkite.com/docs/agent;
license = stdenv.lib.licenses.mit;
maintainers = [ stdenv.lib.maintainers.pawelpacana ];
platforms = stdenv.lib.platforms.linux;
};
}