forked from mirrors/nixpkgs
k3sup: init at 0.11.3
This commit is contained in:
parent
3a3fa1b0f2
commit
07895c78f7
48
pkgs/applications/networking/cluster/k3sup/default.nix
Normal file
48
pkgs/applications/networking/cluster/k3sup/default.nix
Normal file
|
@ -0,0 +1,48 @@
|
|||
{ lib
|
||||
, buildGoModule
|
||||
, fetchFromGitHub
|
||||
, makeWrapper
|
||||
, bash
|
||||
, openssh
|
||||
}:
|
||||
|
||||
buildGoModule rec {
|
||||
pname = "k3sup";
|
||||
version = "0.11.3";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "alexellis";
|
||||
repo = "k3sup";
|
||||
rev = version;
|
||||
sha256 = "sha256-6WYUmC2uVHFGLsfkA2EUOWmmo1dSKJzI4MEdRnlLgYY=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
||||
vendorSha256 = "sha256-Pd+BgPWoxf1AhP0o5SgFSvy4LyUQB7peKWJk0BMy7ds=";
|
||||
|
||||
postConfigure = ''
|
||||
substituteInPlace vendor/github.com/alexellis/go-execute/pkg/v1/exec.go \
|
||||
--replace "/bin/bash" "${bash}/bin/bash"
|
||||
'';
|
||||
|
||||
CGO_ENABLED = 0;
|
||||
|
||||
ldflags = [
|
||||
"-s" "-w"
|
||||
"-X github.com/alexellis/k3sup/cmd.GitCommit=ref/tags/${version}"
|
||||
"-X github.com/alexellis/k3sup/cmd.Version=${version}"
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
wrapProgram "$out/bin/k3sup" \
|
||||
--prefix PATH : ${lib.makeBinPath [ openssh ]}
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/alexellis/k3sup";
|
||||
description = "Bootstrap Kubernetes with k3s over SSH";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ welteki ];
|
||||
};
|
||||
}
|
|
@ -26660,6 +26660,8 @@ with pkgs;
|
|||
|
||||
k3s = callPackage ../applications/networking/cluster/k3s { };
|
||||
|
||||
k3sup = callPackage ../applications/networking/cluster/k3sup {};
|
||||
|
||||
kconf = callPackage ../applications/networking/cluster/kconf { };
|
||||
|
||||
kail = callPackage ../tools/networking/kail { };
|
||||
|
|
Loading…
Reference in a new issue