From 2690f30fd334689b228579fb44f7e3b02c9f138a Mon Sep 17 00:00:00 2001 From: Colin Arnott Date: Wed, 30 Nov 2022 04:43:26 +0000 Subject: [PATCH 1/2] rke: init at 1.4.1 Fixes #143217 --- .../networking/cluster/rke/default.nix | 25 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 27 insertions(+) create mode 100644 pkgs/applications/networking/cluster/rke/default.nix diff --git a/pkgs/applications/networking/cluster/rke/default.nix b/pkgs/applications/networking/cluster/rke/default.nix new file mode 100644 index 000000000000..f21db14ed626 --- /dev/null +++ b/pkgs/applications/networking/cluster/rke/default.nix @@ -0,0 +1,25 @@ +{ lib, buildGoModule, fetchFromGitHub }: + +buildGoModule rec { + pname = "rke"; + version = "1.4.1"; + + src = fetchFromGitHub { + owner = "rancher"; + repo = pname; + rev = "v${version}"; + hash = "sha256-H5T7Hr6/YL93lbCLOxfQ+Kmv3C+FS074418mHhBV3Bs="; + }; + + vendorHash = "sha256-zV1lrJhzrUAcEk6jYLCFrHcYw3CZart46qXErCTjZyQ="; + + ldflags = [ "-s" "-w" "-X=main.VERSION=v${version}" ]; + + meta = with lib; { + homepage = "https://github.com/rancher/rke"; + description = "An extremely simple, lightning fast Kubernetes distribution that runs entirely within containers"; + changelog = "https://github.com/rancher/rke/releases/tag/v${version}"; + license = licenses.asl20; + maintainers = with maintainers; [ urandom ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 89c70a3400dd..4fcff22b77a7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -31776,6 +31776,8 @@ with pkgs; rkdeveloptool-pine64 = callPackage ../misc/rkdeveloptool-pine64 { }; + rke = callPackage ../applications/networking/cluster/rke {}; + rocketchat-desktop = callPackage ../applications/networking/instant-messengers/rocketchat-desktop { }; rofi-unwrapped = callPackage ../applications/misc/rofi { }; From 1beb3948ae2b8637e2faa0289aa5337f4a1a00ba Mon Sep 17 00:00:00 2001 From: figsoda Date: Wed, 30 Nov 2022 09:04:49 -0500 Subject: [PATCH 2/2] rke: exclude codegen binary --- pkgs/applications/networking/cluster/rke/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkgs/applications/networking/cluster/rke/default.nix b/pkgs/applications/networking/cluster/rke/default.nix index f21db14ed626..0d76b62a8e18 100644 --- a/pkgs/applications/networking/cluster/rke/default.nix +++ b/pkgs/applications/networking/cluster/rke/default.nix @@ -13,6 +13,8 @@ buildGoModule rec { vendorHash = "sha256-zV1lrJhzrUAcEk6jYLCFrHcYw3CZart46qXErCTjZyQ="; + subPackages = [ "." ]; + ldflags = [ "-s" "-w" "-X=main.VERSION=v${version}" ]; meta = with lib; {