about summary refs log tree commit diff
path: root/nixpkgs/pkgs/applications/networking/cluster/k3s
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/applications/networking/cluster/k3s')
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_26/chart-versions.nix10
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_26/versions.nix14
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/chart-versions.nix16
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/versions.nix12
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/chart-versions.nix16
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/versions.nix12
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/chart-versions.nix16
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/versions.nix16
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_30/chart-versions.nix10
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/1_30/versions.nix14
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/builder.nix161
-rw-r--r--nixpkgs/pkgs/applications/networking/cluster/k3s/default.nix54
-rwxr-xr-xnixpkgs/pkgs/applications/networking/cluster/k3s/update-script.sh16
13 files changed, 230 insertions, 137 deletions
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_26/chart-versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_26/chart-versions.nix
deleted file mode 100644
index 1acca4d0e101..000000000000
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_26/chart-versions.nix
+++ /dev/null
@@ -1,10 +0,0 @@
-{
-    traefik-crd  = {
-        url = "https://k3s.io/k3s-charts/assets/traefik-crd/traefik-crd-25.0.2+up25.0.0.tgz";
-        sha256 = "0jygzsn5pxzf7423x5iqfffgx5xvm7c7hfck46y7vpv1fdkiipcq";
-    };
-    traefik = {
-        url = "https://k3s.io/k3s-charts/assets/traefik/traefik-25.0.2+up25.0.0.tgz";
-        sha256 = "1g9n19lnqdkmbbr3rnbwc854awha0kqqfwyxanyx1lg5ww8ldp89";
-    };
-}
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_26/versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_26/versions.nix
deleted file mode 100644
index 6ac3414b1b0e..000000000000
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_26/versions.nix
+++ /dev/null
@@ -1,14 +0,0 @@
-{
-  k3sVersion = "1.26.15+k3s1";
-  k3sCommit = "132972364806998c35d250153e2af245f9ecf18d";
-  k3sRepoSha256 = "13iwmjxyf71l2g66kxdivnj21bf9lmr5p4qlp8kmysm23w2badj9";
-  k3sVendorHash = "sha256-xoscRchOK4p3d1DAnxbJq7oIvxIn1twePmOBDdfXzw8=";
-  chartVersions = import ./chart-versions.nix;
-  k3sRootVersion = "0.12.2";
-  k3sRootSha256 = "1gjynvr350qni5mskgm7pcc7alss4gms4jmkiv453vs8mmma9c9k";
-  k3sCNIVersion = "1.4.0-k3s2";
-  k3sCNISha256 = "17dg6jgjx18nrlyfmkv14dhzxsljz4774zgwz5dchxcf38bvarqa";
-  containerdVersion = "1.7.11-k3s2.26";
-  containerdSha256 = "0413a81kzb05xkklwyngg8g6a0w4icsi938rim69jmr2sijc89ww";
-  criCtlVersion = "1.26.0-rc.0-k3s1";
-}
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/chart-versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/chart-versions.nix
index 1acca4d0e101..aaaa3d4c2970 100644
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/chart-versions.nix
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/chart-versions.nix
@@ -1,10 +1,10 @@
 {
-    traefik-crd  = {
-        url = "https://k3s.io/k3s-charts/assets/traefik-crd/traefik-crd-25.0.2+up25.0.0.tgz";
-        sha256 = "0jygzsn5pxzf7423x5iqfffgx5xvm7c7hfck46y7vpv1fdkiipcq";
-    };
-    traefik = {
-        url = "https://k3s.io/k3s-charts/assets/traefik/traefik-25.0.2+up25.0.0.tgz";
-        sha256 = "1g9n19lnqdkmbbr3rnbwc854awha0kqqfwyxanyx1lg5ww8ldp89";
-    };
+  traefik-crd = {
+    url = "https://k3s.io/k3s-charts/assets/traefik-crd/traefik-crd-25.0.3+up25.0.0.tgz";
+    sha256 = "1z693i4kd3jyf26ccnb0sxjyxadipl6k13n7jyg5v4y93fv1rpdw";
+  };
+  traefik = {
+    url = "https://k3s.io/k3s-charts/assets/traefik/traefik-25.0.3+up25.0.0.tgz";
+    sha256 = "1a24qlp7c6iri72ka1i37l1lzn13xibrd26dy295z2wzr55gg7if";
+  };
 }
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/versions.nix
index 928337553966..508ef6c4139d 100644
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/versions.nix
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_27/versions.nix
@@ -1,14 +1,14 @@
 {
-  k3sVersion = "1.27.12+k3s1";
-  k3sCommit = "78ad57567c9eb1fd1831986f5fd7b4024add1767";
-  k3sRepoSha256 = "1j6xb3af4ypqq5m6a8x2yc2515zvlgqzfsfindjm9cbmq5iisphq";
-  k3sVendorHash = "sha256-65cmpRwD9C+fcbBSv1YpeukO7bfGngsLv/rk6sM59gU=";
+  k3sVersion = "1.27.13+k3s1";
+  k3sCommit = "b23f142da8589854cc7ee45da08d96b5ad1ee1ff";
+  k3sRepoSha256 = "052998644il0qra7cdpvmy007gw16k2rvyg418m1j02pm9a3zn10";
+  k3sVendorHash = "sha256-rQZZnleRekkU1+I38LmFnnatZPuS+K1jbBwA+Dmc0jo=";
   chartVersions = import ./chart-versions.nix;
   k3sRootVersion = "0.12.2";
   k3sRootSha256 = "1gjynvr350qni5mskgm7pcc7alss4gms4jmkiv453vs8mmma9c9k";
   k3sCNIVersion = "1.4.0-k3s2";
   k3sCNISha256 = "17dg6jgjx18nrlyfmkv14dhzxsljz4774zgwz5dchxcf38bvarqa";
-  containerdVersion = "1.7.11-k3s2.27";
-  containerdSha256 = "0xjxc5dgh3drk2glvcabd885damjffp9r4cs0cm1zgnrrbhlipra";
+  containerdVersion = "1.7.15-k3s1.27";
+  containerdSha256 = "0bjxw174prhq8izmgrmpyljfxzrj0lh5d0w04g3lyn0rp3kwxqsl";
   criCtlVersion = "1.26.0-rc.0-k3s1";
 }
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/chart-versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/chart-versions.nix
index 1acca4d0e101..aaaa3d4c2970 100644
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/chart-versions.nix
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/chart-versions.nix
@@ -1,10 +1,10 @@
 {
-    traefik-crd  = {
-        url = "https://k3s.io/k3s-charts/assets/traefik-crd/traefik-crd-25.0.2+up25.0.0.tgz";
-        sha256 = "0jygzsn5pxzf7423x5iqfffgx5xvm7c7hfck46y7vpv1fdkiipcq";
-    };
-    traefik = {
-        url = "https://k3s.io/k3s-charts/assets/traefik/traefik-25.0.2+up25.0.0.tgz";
-        sha256 = "1g9n19lnqdkmbbr3rnbwc854awha0kqqfwyxanyx1lg5ww8ldp89";
-    };
+  traefik-crd = {
+    url = "https://k3s.io/k3s-charts/assets/traefik-crd/traefik-crd-25.0.3+up25.0.0.tgz";
+    sha256 = "1z693i4kd3jyf26ccnb0sxjyxadipl6k13n7jyg5v4y93fv1rpdw";
+  };
+  traefik = {
+    url = "https://k3s.io/k3s-charts/assets/traefik/traefik-25.0.3+up25.0.0.tgz";
+    sha256 = "1a24qlp7c6iri72ka1i37l1lzn13xibrd26dy295z2wzr55gg7if";
+  };
 }
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/versions.nix
index b8e68bb87740..67991dfd6fc7 100644
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/versions.nix
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_28/versions.nix
@@ -1,14 +1,14 @@
 {
-  k3sVersion = "1.28.8+k3s1";
-  k3sCommit = "653dd61aaa2d0ef8bd83ac4dbc6d150dde792efc";
-  k3sRepoSha256 = "0pf8xw1m56m2s8i99vxj4i2l7fz7388kiynwzfrck43jb7v7kbbw";
-  k3sVendorHash = "sha256-wglwRW2RO9QJI6CRLgkVg5Upt6R0M3gX76zy0kT02ec=";
+  k3sVersion = "1.28.9+k3s1";
+  k3sCommit = "289a1a3edbc0f6ee5a7f91bf96aa1ed1b743bd1f";
+  k3sRepoSha256 = "0kms6r10k6v037r5lxxrp90bnynrgyrn61kqnzy2f5avny4blikh";
+  k3sVendorHash = "sha256-iUp2Maua3BnrC4Jq2ij0uOW5gYYZfz6e+TEdDtN0PT8=";
   chartVersions = import ./chart-versions.nix;
   k3sRootVersion = "0.12.2";
   k3sRootSha256 = "1gjynvr350qni5mskgm7pcc7alss4gms4jmkiv453vs8mmma9c9k";
   k3sCNIVersion = "1.4.0-k3s2";
   k3sCNISha256 = "17dg6jgjx18nrlyfmkv14dhzxsljz4774zgwz5dchxcf38bvarqa";
-  containerdVersion = "1.7.11-k3s2";
-  containerdSha256 = "0279sil02wz7310xhrgmdbc0r2qibj9lafy0i9k24jdrh74icmib";
+  containerdVersion = "1.7.15-k3s1";
+  containerdSha256 = "18hlj4ixjk7wvamfd66xyc0cax2hs9s7yjvlx52afxdc73194y0f";
   criCtlVersion = "1.26.0-rc.0-k3s1";
 }
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/chart-versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/chart-versions.nix
index 1acca4d0e101..aaaa3d4c2970 100644
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/chart-versions.nix
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/chart-versions.nix
@@ -1,10 +1,10 @@
 {
-    traefik-crd  = {
-        url = "https://k3s.io/k3s-charts/assets/traefik-crd/traefik-crd-25.0.2+up25.0.0.tgz";
-        sha256 = "0jygzsn5pxzf7423x5iqfffgx5xvm7c7hfck46y7vpv1fdkiipcq";
-    };
-    traefik = {
-        url = "https://k3s.io/k3s-charts/assets/traefik/traefik-25.0.2+up25.0.0.tgz";
-        sha256 = "1g9n19lnqdkmbbr3rnbwc854awha0kqqfwyxanyx1lg5ww8ldp89";
-    };
+  traefik-crd = {
+    url = "https://k3s.io/k3s-charts/assets/traefik-crd/traefik-crd-25.0.3+up25.0.0.tgz";
+    sha256 = "1z693i4kd3jyf26ccnb0sxjyxadipl6k13n7jyg5v4y93fv1rpdw";
+  };
+  traefik = {
+    url = "https://k3s.io/k3s-charts/assets/traefik/traefik-25.0.3+up25.0.0.tgz";
+    sha256 = "1a24qlp7c6iri72ka1i37l1lzn13xibrd26dy295z2wzr55gg7if";
+  };
 }
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/versions.nix
index cf1f57e0fe60..31dd51fa9ca6 100644
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/versions.nix
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_29/versions.nix
@@ -1,14 +1,14 @@
 {
-  k3sVersion = "1.29.3+k3s1";
-  k3sCommit = "8aecc26b0f167d5e9e4e9fbcfd5a471488bf5957";
-  k3sRepoSha256 = "12285mhwi6cifsw3gjxxmd1g2i5f7vkdgzdc6a78rkvnx7z1j3p3";
-  k3sVendorHash = "sha256-pID2h/rvvKyfHWoglYPbbliAby+9R2zoh7Ajd36qjVQ=";
+  k3sVersion = "1.29.4+k3s1";
+  k3sCommit = "94e29e2ef5d79904f730e2024c8d1682b901b2d5";
+  k3sRepoSha256 = "0kkhd2fnlmjanzvwgdclmbg6azw3r1a2lj5207716pavxmb9ld7y";
+  k3sVendorHash = "sha256-wOX+ktGPFYUKLZBK/bQhWWG+SnRCkNYnk3Tz8wpMo5A=";
   chartVersions = import ./chart-versions.nix;
-  k3sRootVersion = "0.12.2";
-  k3sRootSha256 = "1gjynvr350qni5mskgm7pcc7alss4gms4jmkiv453vs8mmma9c9k";
+  k3sRootVersion = "0.13.0";
+  k3sRootSha256 = "1jq5f0lm08abx5ikarf92z56fvx4kjpy2nmzaazblb34lajw87vj";
   k3sCNIVersion = "1.4.0-k3s2";
   k3sCNISha256 = "17dg6jgjx18nrlyfmkv14dhzxsljz4774zgwz5dchxcf38bvarqa";
-  containerdVersion = "1.7.11-k3s2";
-  containerdSha256 = "0279sil02wz7310xhrgmdbc0r2qibj9lafy0i9k24jdrh74icmib";
+  containerdVersion = "1.7.15-k3s1";
+  containerdSha256 = "18hlj4ixjk7wvamfd66xyc0cax2hs9s7yjvlx52afxdc73194y0f";
   criCtlVersion = "1.29.0-k3s1";
 }
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_30/chart-versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_30/chart-versions.nix
new file mode 100644
index 000000000000..aaaa3d4c2970
--- /dev/null
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_30/chart-versions.nix
@@ -0,0 +1,10 @@
+{
+  traefik-crd = {
+    url = "https://k3s.io/k3s-charts/assets/traefik-crd/traefik-crd-25.0.3+up25.0.0.tgz";
+    sha256 = "1z693i4kd3jyf26ccnb0sxjyxadipl6k13n7jyg5v4y93fv1rpdw";
+  };
+  traefik = {
+    url = "https://k3s.io/k3s-charts/assets/traefik/traefik-25.0.3+up25.0.0.tgz";
+    sha256 = "1a24qlp7c6iri72ka1i37l1lzn13xibrd26dy295z2wzr55gg7if";
+  };
+}
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/1_30/versions.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_30/versions.nix
new file mode 100644
index 000000000000..bc7c2d99c62c
--- /dev/null
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/1_30/versions.nix
@@ -0,0 +1,14 @@
+{
+  k3sVersion = "1.30.0+k3s1";
+  k3sCommit = "14549535f13c63fc239ba055d36d590e68b01503";
+  k3sRepoSha256 = "1dph6clzzanlx7dbdzpamnw7gpw98j850my28lcb3zdzhvhsc74b";
+  k3sVendorHash = "sha256-YBWiIf8F71ibR7sCiYtmsAcY1MsvkhTD/K45tOHQC5w=";
+  chartVersions = import ./chart-versions.nix;
+  k3sRootVersion = "0.13.0";
+  k3sRootSha256 = "1jq5f0lm08abx5ikarf92z56fvx4kjpy2nmzaazblb34lajw87vj";
+  k3sCNIVersion = "1.4.0-k3s2";
+  k3sCNISha256 = "17dg6jgjx18nrlyfmkv14dhzxsljz4774zgwz5dchxcf38bvarqa";
+  containerdVersion = "1.7.15-k3s1";
+  containerdSha256 = "18hlj4ixjk7wvamfd66xyc0cax2hs9s7yjvlx52afxdc73194y0f";
+  criCtlVersion = "1.29.0-k3s1";
+}
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/builder.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/builder.nix
index b5f017b85b05..247ab0f339da 100644
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/builder.nix
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/builder.nix
@@ -29,33 +29,42 @@ lib:
 # currently.
 # It is likely we will have to split out additional builders for additional
 # versions in the future, or customize this one further.
-{ lib
-, fetchpatch
-, makeWrapper
-, socat
-, iptables
-, iproute2
-, ipset
-, bridge-utils
-, btrfs-progs
-, conntrack-tools
-, buildGoModule
-, runc
-, rsync
-, kmod
-, libseccomp
-, pkg-config
-, ethtool
-, util-linux
-, fetchFromGitHub
-, fetchurl
-, fetchzip
-, fetchgit
-, zstd
-, yq-go
-, sqlite
-, nixosTests
-, pkgsBuildBuild
+{
+  lib,
+  makeWrapper,
+  socat,
+  iptables,
+  iproute2,
+  ipset,
+  bridge-utils,
+  btrfs-progs,
+  conntrack-tools,
+  buildGoModule,
+  runc,
+  rsync,
+  kmod,
+  libseccomp,
+  pkg-config,
+  ethtool,
+  util-linux,
+  fetchFromGitHub,
+  fetchurl,
+  fetchzip,
+  fetchgit,
+  zstd,
+  yq-go,
+  sqlite,
+  nixosTests,
+  pkgsBuildBuild,
+  go,
+  runCommand,
+  bash,
+  procps,
+  coreutils,
+  gnugrep,
+  findutils,
+  gnused,
+  systemd,
 }:
 
 # k3s is a kinda weird derivation. One of the main points of k3s is the
@@ -83,7 +92,13 @@ let
     description = "A lightweight Kubernetes distribution";
     license = licenses.asl20;
     homepage = "https://k3s.io";
-    maintainers = with maintainers; [ euank mic92 superherointj yajo ];
+    maintainers = with maintainers; [
+      euank
+      mic92
+      superherointj
+      wrmilling
+      yajo
+    ];
     platforms = platforms.linux;
 
     # resolves collisions with other installations of kubectl, crictl, ctr
@@ -93,8 +108,9 @@ let
 
   # https://github.com/k3s-io/k3s/blob/5fb370e53e0014dc96183b8ecb2c25a61e891e76/scripts/build#L19-L40
   versionldflags = [
-    "-X github.com/rancher/k3s/pkg/version.Version=v${k3sVersion}"
-    "-X github.com/rancher/k3s/pkg/version.GitCommit=${lib.substring 0 8 k3sCommit}"
+    "-X github.com/k3s-io/k3s/pkg/version.Version=v${k3sVersion}"
+    "-X github.com/k3s-io/k3s/pkg/version.GitCommit=${lib.substring 0 8 k3sCommit}"
+    "-X github.com/k3s-io/k3s/pkg/version.UpstreamGolang=go${go.version}"
     "-X k8s.io/client-go/pkg/version.gitVersion=v${k3sVersion}"
     "-X k8s.io/client-go/pkg/version.gitCommit=${k3sCommit}"
     "-X k8s.io/client-go/pkg/version.gitTreeState=clean"
@@ -156,6 +172,42 @@ let
     rev = "v${k3sVersion}";
     sha256 = k3sRepoSha256;
   };
+
+  # Modify the k3s installer script so that we can let it install only
+  # killall.sh
+  k3sKillallSh = runCommand "k3s-killall.sh" { } ''
+    # Copy the upstream k3s install script except for the last lines that
+    # actually run the install process
+    sed --quiet '/# --- run the install process --/q;p' ${k3sRepo}/install.sh > install.sh
+
+    # Let killall expect "containerd-shim" in the Nix store
+    to_replace="k3s/data/\[\^/\]\*/bin/containerd-shim"
+    replacement="/nix/store/.*k3s-containerd.*/bin/containerd-shim"
+    changes=$(sed -i "s|$to_replace|$replacement| w /dev/stdout" install.sh)
+    if [ -z "$changes" ]; then
+      echo "failed to replace \"$to_replace\" in k3s installer script (install.sh)"
+      exit 1
+    fi
+
+    remove_matching_line() {
+      line_to_delete=$(grep -n "$1" install.sh | cut -d : -f 1 || true)
+      if [ -z $line_to_delete ]; then
+        echo "failed to find expression \"$1\" in k3s installer script (install.sh)"
+        exit 1
+      fi
+      sed -i "''${line_to_delete}d" install.sh
+    }
+
+    # Don't change mode and owner of killall
+    remove_matching_line "chmod.*KILLALL_K3S_SH"
+    remove_matching_line "chown.*KILLALL_K3S_SH"
+
+    # Execute only the "create_killall" function of the installer script
+    sed -i '$acreate_killall' install.sh
+
+    KILLALL_K3S_SH=$out bash install.sh
+  '';
+
   # Stage 1 of the k3s build:
   # Let's talk about how k3s is structured.
   # One of the ideas of k3s is that there's the single "k3s" binary which can
@@ -185,22 +237,20 @@ let
     src = k3sRepo;
     vendorHash = k3sVendorHash;
 
-    patches =
-      # Disable: Add runtime checking of golang version
-      (fetchpatch {
-        # https://github.com/k3s-io/k3s/pull/9054
-        url = "https://github.com/k3s-io/k3s/commit/b297996b9252b02e56e9425f55f6becbf6bb7832.patch";
-        hash = "sha256-xBOY2jnLhT9dtVKtq26V9QUnuX1q6E/9UcO9IaU719U=";
-        revert = true;
-      });
-
     nativeBuildInputs = [ pkg-config ];
-    buildInputs = [ libseccomp sqlite.dev ];
+    buildInputs = [
+      libseccomp
+      sqlite.dev
+    ];
 
     subPackages = [ "cmd/server" ];
     ldflags = versionldflags;
 
-    tags = [ "ctrd" "libsqlite3" "linux" ];
+    tags = [
+      "ctrd"
+      "libsqlite3"
+      "linux"
+    ];
 
     # create the multicall symlinks for k3s
     postInstall = ''
@@ -246,7 +296,11 @@ buildGoModule rec {
   pname = "k3s";
   version = k3sVersion;
 
-  tags = [ "libsqlite3" "linux" "ctrd" ];
+  tags = [
+    "libsqlite3"
+    "linux"
+    "ctrd"
+  ];
   src = k3sRepo;
   vendorHash = k3sVendorHash;
 
@@ -286,6 +340,16 @@ buildGoModule rec {
     runc
   ];
 
+  k3sKillallDeps = [
+    bash
+    systemd
+    procps
+    coreutils
+    gnugrep
+    findutils
+    gnused
+  ];
+
   buildInputs = k3sRuntimeDeps;
 
   nativeBuildInputs = [
@@ -342,6 +406,9 @@ buildGoModule rec {
     ln -s $out/bin/k3s $out/bin/kubectl
     ln -s $out/bin/k3s $out/bin/crictl
     ln -s $out/bin/k3s $out/bin/ctr
+    install -m 0755 ${k3sKillallSh} -D $out/bin/k3s-killall.sh
+    wrapProgram $out/bin/k3s-killall.sh \
+      --prefix PATH : ${lib.makeBinPath (k3sRuntimeDeps ++ k3sKillallDeps)}
   '';
 
   doInstallCheck = true;
@@ -351,15 +418,17 @@ buildGoModule rec {
 
   passthru.updateScript = updateScript;
 
-  passthru.mkTests = version:
-    let k3s_version = "k3s_" + lib.replaceStrings ["."] ["_"] (lib.versions.majorMinor version);
-    in {
+  passthru.mkTests =
+    version:
+    let
+      k3s_version = "k3s_" + lib.replaceStrings [ "." ] [ "_" ] (lib.versions.majorMinor version);
+    in
+    {
       etcd = nixosTests.k3s.etcd.${k3s_version};
       single-node = nixosTests.k3s.single-node.${k3s_version};
       multi-node = nixosTests.k3s.multi-node.${k3s_version};
     };
   passthru.tests = passthru.mkTests k3sVersion;
 
-
   meta = baseMeta;
 }
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/default.nix b/nixpkgs/pkgs/applications/networking/cluster/k3s/default.nix
index 934f5a3691cd..6e7cfb0d1325 100644
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/default.nix
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/default.nix
@@ -12,22 +12,46 @@ let
   extraArgs = builtins.removeAttrs args [ "callPackage" ];
 in
 {
-  k3s_1_26 = common ((import ./1_26/versions.nix) // {
-    updateScript = [ ./update-script.sh "26" ];
-  }) extraArgs;
+  # 1_27 can be built with the same builder as 1_30
+  k3s_1_27 = common (
+    (import ./1_27/versions.nix)
+    // {
+      updateScript = [
+        ./update-script.sh
+        "27"
+      ];
+    }
+  ) extraArgs;
 
-  # 1_27 can be built with the same builder as 1_26
-  k3s_1_27 = common ((import ./1_27/versions.nix) // {
-    updateScript = [ ./update-script.sh "27" ];
-  }) extraArgs;
+  # 1_28 can be built with the same builder as 1_30
+  k3s_1_28 = common (
+    (import ./1_28/versions.nix)
+    // {
+      updateScript = [
+        ./update-script.sh
+        "28"
+      ];
+    }
+  ) extraArgs;
 
-  # 1_28 can be built with the same builder as 1_26
-  k3s_1_28 = common ((import ./1_28/versions.nix) // {
-    updateScript = [ ./update-script.sh "28" ];
-  }) extraArgs;
+  # 1_29 can be built with the same builder as 1_30
+  k3s_1_29 = common (
+    (import ./1_29/versions.nix)
+    // {
+      updateScript = [
+        ./update-script.sh
+        "29"
+      ];
+    }
+  ) extraArgs;
 
-  # 1_29 can be built with the same builder as 1_26
-  k3s_1_29 = common ((import ./1_29/versions.nix) // {
-    updateScript = [ ./update-script.sh "29" ];
-  }) extraArgs;
+  k3s_1_30 = common (
+    (import ./1_30/versions.nix)
+    // {
+      updateScript = [
+        ./update-script.sh
+        "30"
+      ];
+    }
+  ) extraArgs;
 }
diff --git a/nixpkgs/pkgs/applications/networking/cluster/k3s/update-script.sh b/nixpkgs/pkgs/applications/networking/cluster/k3s/update-script.sh
index 9f534f4d179a..ca7d21bff478 100755
--- a/nixpkgs/pkgs/applications/networking/cluster/k3s/update-script.sh
+++ b/nixpkgs/pkgs/applications/networking/cluster/k3s/update-script.sh
@@ -57,14 +57,14 @@ CHARTS_URL=https://k3s.io/k3s-charts/assets
 rm -f chart-versions.nix.update
 cat > chart-versions.nix.update <<EOF
 {
-    traefik-crd  = {
-        url = "${CHARTS_URL}/traefik-crd/${CHART_FILES[0]}";
-        sha256 = "$(nix-prefetch-url --quiet "${CHARTS_URL}/traefik-crd/${CHART_FILES[0]}")";
-    };
-    traefik = {
-        url = "${CHARTS_URL}/traefik/${CHART_FILES[1]}";
-        sha256 = "$(nix-prefetch-url --quiet "${CHARTS_URL}/traefik/${CHART_FILES[1]}")";
-    };
+  traefik-crd = {
+    url = "${CHARTS_URL}/traefik-crd/${CHART_FILES[0]}";
+    sha256 = "$(nix-prefetch-url --quiet "${CHARTS_URL}/traefik-crd/${CHART_FILES[0]}")";
+  };
+  traefik = {
+    url = "${CHARTS_URL}/traefik/${CHART_FILES[1]}";
+    sha256 = "$(nix-prefetch-url --quiet "${CHARTS_URL}/traefik/${CHART_FILES[1]}")";
+  };
 }
 EOF
 mv chart-versions.nix.update chart-versions.nix