summary refs log tree commit diff
path: root/pkgs/development/tools/continuous-integration
diff options
context:
space:
mode:
authorRodney Lorrimar <dev@rodney.id.au>2018-04-25 13:47:26 +0100
committerzimbatm <zimbatm@zimbatm.com>2018-04-25 13:47:26 +0100
commitca7d98399976be0dd562d1f8ecd62ed3e5cd5656 (patch)
tree8ca6c50c6e5911cd640951a58060f02431b31051 /pkgs/development/tools/continuous-integration
parent8d58b1a0a019bb00ac6fb1792fe36e81847b7c92 (diff)
downloadnixpkgs-ca7d98399976be0dd562d1f8ecd62ed3e5cd5656.tar
nixpkgs-ca7d98399976be0dd562d1f8ecd62ed3e5cd5656.tar.gz
nixpkgs-ca7d98399976be0dd562d1f8ecd62ed3e5cd5656.tar.bz2
nixpkgs-ca7d98399976be0dd562d1f8ecd62ed3e5cd5656.tar.lz
nixpkgs-ca7d98399976be0dd562d1f8ecd62ed3e5cd5656.tar.xz
nixpkgs-ca7d98399976be0dd562d1f8ecd62ed3e5cd5656.tar.zst
nixpkgs-ca7d98399976be0dd562d1f8ecd62ed3e5cd5656.zip
buildkite-agent3: init at 3.0.1 (#39471)
New stable release. Version 2.6 is kept for backwards compatibility.

https://github.com/buildkite/agent/releases/tag/v3.0.0
https://github.com/buildkite/agent/releases/tag/v3.0.1
Diffstat (limited to 'pkgs/development/tools/continuous-integration')
-rw-r--r--pkgs/development/tools/continuous-integration/buildkite-agent/2.x.nix12
-rw-r--r--pkgs/development/tools/continuous-integration/buildkite-agent/3.x.nix12
-rw-r--r--pkgs/development/tools/continuous-integration/buildkite-agent/generic.nix (renamed from pkgs/development/tools/continuous-integration/buildkite-agent/default.nix)22
3 files changed, 33 insertions, 13 deletions
diff --git a/pkgs/development/tools/continuous-integration/buildkite-agent/2.x.nix b/pkgs/development/tools/continuous-integration/buildkite-agent/2.x.nix
new file mode 100644
index 00000000000..6a73e258182
--- /dev/null
+++ b/pkgs/development/tools/continuous-integration/buildkite-agent/2.x.nix
@@ -0,0 +1,12 @@
+{ callPackage, fetchFromGitHub, ... } @ args:
+
+callPackage ./generic.nix (args // rec {
+  src = fetchFromGitHub {
+    owner = "buildkite";
+    repo = "agent";
+    rev = "v${version}";
+    sha256 = "07065hhhb418w5qlqnyiap45r59paysysbwz1l7dmaw3j4q8m8rg";
+  };
+  version = "2.6.10";
+  hasBootstrapScript = true;
+})
diff --git a/pkgs/development/tools/continuous-integration/buildkite-agent/3.x.nix b/pkgs/development/tools/continuous-integration/buildkite-agent/3.x.nix
new file mode 100644
index 00000000000..2ceaee5650b
--- /dev/null
+++ b/pkgs/development/tools/continuous-integration/buildkite-agent/3.x.nix
@@ -0,0 +1,12 @@
+{ callPackage, fetchFromGitHub, ... } @ args:
+
+callPackage ./generic.nix (args // rec {
+  src = fetchFromGitHub {
+    owner = "buildkite";
+    repo = "agent";
+    rev = "v${version}";
+    sha256 = "09smyrzp1xkczlmh8vqb7bmjb2b5d6yf9birjgaw36c6m44bpfvs";
+  };
+  version = "3.0.1";
+  hasBootstrapScript = false;
+})
diff --git a/pkgs/development/tools/continuous-integration/buildkite-agent/default.nix b/pkgs/development/tools/continuous-integration/buildkite-agent/generic.nix
index 7a5f2f44823..8aa02ac307d 100644
--- a/pkgs/development/tools/continuous-integration/buildkite-agent/default.nix
+++ b/pkgs/development/tools/continuous-integration/buildkite-agent/generic.nix
@@ -1,19 +1,13 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, makeWrapper, coreutils, git, openssh, bash, gnused, gnugrep }:
+{ stdenv, buildGoPackage, makeWrapper, coreutils, git, openssh, bash, gnused, gnugrep
+, src, version, hasBootstrapScript
+, ... }:
 let
-  version = "2.6.10";
   goPackagePath = "github.com/buildkite/agent";
 in
 buildGoPackage {
   name = "buildkite-agent-${version}";
 
-  inherit goPackagePath;
-
-  src = fetchFromGitHub {
-    owner = "buildkite";
-    repo = "agent";
-    rev = "v${version}";
-    sha256 = "07065hhhb418w5qlqnyiap45r59paysysbwz1l7dmaw3j4q8m8rg";
-  };
+  inherit goPackagePath src;
 
   nativeBuildInputs = [ makeWrapper ];
 
@@ -22,18 +16,20 @@ buildGoPackage {
   noAuditTmpdir = stdenv.isLinux;
 
   postInstall = ''
+    ${stdenv.lib.optionalString hasBootstrapScript ''
     # Install bootstrap.sh
     mkdir -p $bin/libexec/buildkite-agent
     cp $NIX_BUILD_TOP/go/src/${goPackagePath}/templates/bootstrap.sh $bin/libexec/buildkite-agent
     sed -e "s|#!/bin/bash|#!${bash}/bin/bash|g" -i $bin/libexec/buildkite-agent/bootstrap.sh
+    ''}
 
     # Fix binary name
     mv $bin/bin/{agent,buildkite-agent}
 
     # These are runtime dependencies
     wrapProgram $bin/bin/buildkite-agent \
-      --prefix PATH : '${stdenv.lib.makeBinPath [ openssh git coreutils gnused gnugrep ]}' \
-      --set BUILDKITE_BOOTSTRAP_SCRIPT_PATH $bin/libexec/buildkite-agent/bootstrap.sh
+      ${stdenv.lib.optionalString hasBootstrapScript "--set BUILDKITE_BOOTSTRAP_SCRIPT_PATH $bin/libexec/buildkite-agent/bootstrap.sh"} \
+      --prefix PATH : '${stdenv.lib.makeBinPath [ openssh git coreutils gnused gnugrep ]}'
   '';
 
   meta = with stdenv.lib; {
@@ -47,7 +43,7 @@ buildGoPackage {
     '';
     homepage = https://buildkite.com/docs/agent;
     license = licenses.mit;
-    maintainers = with maintainers; [ pawelpacana zimbatm ];
+    maintainers = with maintainers; [ pawelpacana zimbatm rvl ];
     platforms = platforms.unix;
   };
 }