Skip to content

Commit

Permalink
Update k3s packages and init v1.31.0 (NixOS#339264)
Browse files Browse the repository at this point in the history
  • Loading branch information
marcusramberg authored Sep 5, 2024
2 parents 213c0c8 + d3da752 commit a779daa
Show file tree
Hide file tree
Showing 13 changed files with 110 additions and 50 deletions.
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
{
"airgap-images-amd64": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.28.12%2Bk3s1/k3s-airgap-images-amd64.tar.zst",
"sha256": "0dhzkn5y3ng7blyxj4bwrhbq5qvl3hq1hzg0h9633h8swv0xbsss"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.28.13%2Bk3s1/k3s-airgap-images-amd64.tar.zst",
"sha256": "1v3vyrb86xijyvljs0s0skhxpjbarjqg2sx9m40332dfq9din7xq"
},
"airgap-images-arm": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.28.12%2Bk3s1/k3s-airgap-images-arm.tar.zst",
"sha256": "1225nqsfg7p6iq7a7qibzf3d0r7iwn53hnd9w6l189dxqna97015"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.28.13%2Bk3s1/k3s-airgap-images-arm.tar.zst",
"sha256": "0yifpx6vix5bjzkz81i5rsn89hkpp0rhk77ndl1lgy66pq4csbmm"
},
"airgap-images-arm64": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.28.12%2Bk3s1/k3s-airgap-images-arm64.tar.zst",
"sha256": "1lic564naj9323dkkq0z0y10n3j3yfmhixargqqs60syanfvj2p7"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.28.13%2Bk3s1/k3s-airgap-images-arm64.tar.zst",
"sha256": "1p8zf47pghhjqhrcvmzdbcfxxy78pjpqwvmhm3wdidsa8xyy375a"
},
"images-list": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.28.12%2Bk3s1/k3s-images.txt",
"sha256": "1my3lfs5rfazcnnpsc9dj84dfnxx88xydrl86z6yw5n5p84x4nif"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.28.13%2Bk3s1/k3s-images.txt",
"sha256": "1f1d33jn4g5b6zmzdzzm4ffwfrmjwh60v9gnph0ysxjwsq1k0pxp"
}
}
12 changes: 6 additions & 6 deletions pkgs/applications/networking/cluster/k3s/1_28/versions.nix
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
{
k3sVersion = "1.28.12+k3s1";
k3sCommit = "4717e2a58e04f0ba3d9f43d574a7eff01dea9146";
k3sRepoSha256 = "02wywlqqna0dj9cam6q3ykb3p5mi96f6lclrg5yhjky7jdvkffds";
k3sVendorHash = "sha256-RyUlaGQnfrCm4cB5FRs9IAeF+zn4LzAXmIViU3o30Z4=";
k3sVersion = "1.28.13+k3s1";
k3sCommit = "47737e1c4c941325574e8aa14e4a3af2e596f696";
k3sRepoSha256 = "1x66n36lxcvi5d9bdz0f1w2p24493rh3vbk1pskqd1f3v3fbv7kn";
k3sVendorHash = "sha256-/knBr0l7dZ6lX9QpohyPNrFEi4WQpNM01zOE5bCIB2E=";
chartVersions = import ./chart-versions.nix;
imagesVersions = builtins.fromJSON (builtins.readFile ./images-versions.json);
k3sRootVersion = "0.14.0";
k3sRootSha256 = "15cs9faw3jishsb5nhgmb5ldjc47hkwf7hz2126fp8ahf80m0fcl";
k3sCNIVersion = "1.4.0-k3s2";
k3sCNISha256 = "17dg6jgjx18nrlyfmkv14dhzxsljz4774zgwz5dchxcf38bvarqa";
containerdVersion = "1.7.17-k3s1.28";
containerdSha256 = "0nhhx932j551ran3kkvyp4nmsg5c71mq0g6jrcbs2j4nn7yqdkhm";
containerdVersion = "1.7.20-k3s2.28";
containerdSha256 = "0jqqa9202d94qd7g8d5zy161snlsc42cdjpmp50w4j3pnp2i1cki";
criCtlVersion = "1.26.0-rc.0-k3s1";
}
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
{
"airgap-images-amd64": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.29.7%2Bk3s1/k3s-airgap-images-amd64.tar.zst",
"sha256": "1dyh107ygnlv9gyq2f9jdgrwjiyg25a61id69z48vc60gq480888"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.29.8%2Bk3s1/k3s-airgap-images-amd64.tar.zst",
"sha256": "1v3vyrb86xijyvljs0s0skhxpjbarjqg2sx9m40332dfq9din7xq"
},
"airgap-images-arm": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.29.7%2Bk3s1/k3s-airgap-images-arm.tar.zst",
"sha256": "16l6d1ix3ri1l2wr2k5brg11a1snbkqhqasrk69wrix6diddklrn"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.29.8%2Bk3s1/k3s-airgap-images-arm.tar.zst",
"sha256": "0yifpx6vix5bjzkz81i5rsn89hkpp0rhk77ndl1lgy66pq4csbmm"
},
"airgap-images-arm64": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.29.7%2Bk3s1/k3s-airgap-images-arm64.tar.zst",
"sha256": "0pg4nzh1rf28003yxhl3jklxs41vjjgldviybvnqqp146ib6hy0r"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.29.8%2Bk3s1/k3s-airgap-images-arm64.tar.zst",
"sha256": "1p8zf47pghhjqhrcvmzdbcfxxy78pjpqwvmhm3wdidsa8xyy375a"
},
"images-list": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.29.7%2Bk3s1/k3s-images.txt",
"sha256": "1my3lfs5rfazcnnpsc9dj84dfnxx88xydrl86z6yw5n5p84x4nif"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.29.8%2Bk3s1/k3s-images.txt",
"sha256": "1f1d33jn4g5b6zmzdzzm4ffwfrmjwh60v9gnph0ysxjwsq1k0pxp"
}
}
12 changes: 6 additions & 6 deletions pkgs/applications/networking/cluster/k3s/1_29/versions.nix
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
{
k3sVersion = "1.29.7+k3s1";
k3sCommit = "f246bbc390a05f45431e49617b58013fe06a460d";
k3sRepoSha256 = "0fv628rxxavqmb2gv0ncsx4m8ghn3v6ddn2n06x8q4ar27d9gijg";
k3sVendorHash = "sha256-pAOyGgEaO6ewNv+6yhDt83NZl95rmLseFUs4vlXNH6Q=";
k3sVersion = "1.29.8+k3s1";
k3sCommit = "33fdc35dd67cf6c07989327e992fd26ed89b2449";
k3sRepoSha256 = "0ky5f039nkhdj6y5v9yr6lk875l29c67j6kqc2dzdb3iqbwskcbr";
k3sVendorHash = "sha256-VxVGBvpeKf/nuw09Llf85d4P8oCD2GvD1f0Mxt6fMj8=";
chartVersions = import ./chart-versions.nix;
imagesVersions = builtins.fromJSON (builtins.readFile ./images-versions.json);
k3sRootVersion = "0.14.0";
k3sRootSha256 = "15cs9faw3jishsb5nhgmb5ldjc47hkwf7hz2126fp8ahf80m0fcl";
k3sCNIVersion = "1.4.0-k3s2";
k3sCNISha256 = "17dg6jgjx18nrlyfmkv14dhzxsljz4774zgwz5dchxcf38bvarqa";
containerdVersion = "1.7.17-k3s1";
containerdSha256 = "1j61mbgx346ydvnjd8b07wf7nmvvplx28wi5jjdzi1k688r2hxpf";
containerdVersion = "1.7.20-k3s1";
containerdSha256 = "12ihr3z8vcglv5b0v9ris29zkkkdvjbcp3bf7ym71a0xdbg83s8i";
criCtlVersion = "1.29.0-k3s1";
}
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
{
"airgap-images-amd64": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.30.3%2Bk3s1/k3s-airgap-images-amd64.tar.zst",
"sha256": "1ym7cdm3a2f05wgh4vba2g7q1zihrfvvm2zngcs0gm8djj7hy4d9"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.30.4%2Bk3s1/k3s-airgap-images-amd64.tar.zst",
"sha256": "145sj4gpwdjvfv3bphpdg6db1d83bbwl0shbnsqpjizsm3ifvmm9"
},
"airgap-images-arm": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.30.3%2Bk3s1/k3s-airgap-images-arm.tar.zst",
"sha256": "15mj949msrd30xhqryhpsvx1bi3pywm1z5bmi0h40qyzc1mcfvjk"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.30.4%2Bk3s1/k3s-airgap-images-arm.tar.zst",
"sha256": "0sdkfsjxxi5sq0nxjw7g7r1p7711l74r39y5ss12q85q4sla0m7l"
},
"airgap-images-arm64": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.30.3%2Bk3s1/k3s-airgap-images-arm64.tar.zst",
"sha256": "1k2q6rzczajnrkj57p97fdr7lgmrfv7x54by2syngfwb5in8fhd5"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.30.4%2Bk3s1/k3s-airgap-images-arm64.tar.zst",
"sha256": "1kw85g79rywk6n3wda7ffvjhf030wwj8g3x8n73rgiprvksw4p7j"
},
"images-list": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.30.3%2Bk3s1/k3s-images.txt",
"sha256": "1my3lfs5rfazcnnpsc9dj84dfnxx88xydrl86z6yw5n5p84x4nif"
"url": "https://github.com/k3s-io/k3s/releases/download/v1.30.4%2Bk3s1/k3s-images.txt",
"sha256": "1f1d33jn4g5b6zmzdzzm4ffwfrmjwh60v9gnph0ysxjwsq1k0pxp"
}
}
12 changes: 6 additions & 6 deletions pkgs/applications/networking/cluster/k3s/1_30/versions.nix
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
{
k3sVersion = "1.30.3+k3s1";
k3sCommit = "f646604010affc6a1d3233a8a0870bca46bf80cf";
k3sRepoSha256 = "1sqa4cx5rihrqcnriq7if7sm4hx73ma975yyr5k9nvhg71dvlig3";
k3sVendorHash = "sha256-HMlYdWDUoELpwsfCtyCxVIcFULdvu5gna83lc79AUWc=";
k3sVersion = "1.30.4+k3s1";
k3sCommit = "98262b5dee29fe5ac849a0cef90b5d50292b020b";
k3sRepoSha256 = "1iwg7j0divbh41dx40kz69qkvscvppqb37dqvxayw3ha1yja4sq6";
k3sVendorHash = "sha256-EovTZ3DvDqWFR9vxhtjgcZcPXVk1C0PYNCxEV5XA6wg=";
chartVersions = import ./chart-versions.nix;
imagesVersions = builtins.fromJSON (builtins.readFile ./images-versions.json);
k3sRootVersion = "0.14.0";
k3sRootSha256 = "15cs9faw3jishsb5nhgmb5ldjc47hkwf7hz2126fp8ahf80m0fcl";
k3sCNIVersion = "1.4.0-k3s2";
k3sCNISha256 = "17dg6jgjx18nrlyfmkv14dhzxsljz4774zgwz5dchxcf38bvarqa";
containerdVersion = "1.7.17-k3s1";
containerdSha256 = "1j61mbgx346ydvnjd8b07wf7nmvvplx28wi5jjdzi1k688r2hxpf";
containerdVersion = "1.7.20-k3s1";
containerdSha256 = "12ihr3z8vcglv5b0v9ris29zkkkdvjbcp3bf7ym71a0xdbg83s8i";
criCtlVersion = "1.29.0-k3s1";
}
10 changes: 10 additions & 0 deletions pkgs/applications/networking/cluster/k3s/1_31/chart-versions.nix
Original file line number Diff line number Diff line change
@@ -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";
};
}
18 changes: 18 additions & 0 deletions pkgs/applications/networking/cluster/k3s/1_31/images-versions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"airgap-images-amd64": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.31.0%2Bk3s1/k3s-airgap-images-amd64.tar.zst",
"sha256": "13pakr8nxlbqhqcz40gyjncw4bghk7x7ryb2ynmr5airspqcdrl6"
},
"airgap-images-arm": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.31.0%2Bk3s1/k3s-airgap-images-arm.tar.zst",
"sha256": "0vc2v89qy9gbzfbmfrdb0l5yzyprk7yma5ps0yfj60jd9av07qvh"
},
"airgap-images-arm64": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.31.0%2Bk3s1/k3s-airgap-images-arm64.tar.zst",
"sha256": "10ffa45pm1scavcd5cimdaw29rlc55c9i40qzh3n3451g1yqlmmk"
},
"images-list": {
"url": "https://github.com/k3s-io/k3s/releases/download/v1.31.0%2Bk3s1/k3s-images.txt",
"sha256": "0y4x02fj1iysghq6s88wsiqfpsajrrwrg89m59qk431cii23nrza"
}
}
15 changes: 15 additions & 0 deletions pkgs/applications/networking/cluster/k3s/1_31/versions.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
k3sVersion = "1.31.0+k3s1";
k3sCommit = "34be6d96d17d8d65fda86272b62b752cb0e9c45e";
k3sRepoSha256 = "16yzsx56jmca07jdnzjvy4pcfrvvibv987l1mzdaws1vkm3xqfnw";
k3sVendorHash = "sha256-1uYlvGkW6n4aiUVX/2OjppczdobY/fk1ZaK6j3AEwvM=";
chartVersions = import ./chart-versions.nix;
imagesVersions = builtins.fromJSON (builtins.readFile ./images-versions.json);
k3sRootVersion = "0.14.0";
k3sRootSha256 = "15cs9faw3jishsb5nhgmb5ldjc47hkwf7hz2126fp8ahf80m0fcl";
k3sCNIVersion = "1.4.0-k3s2";
k3sCNISha256 = "17dg6jgjx18nrlyfmkv14dhzxsljz4774zgwz5dchxcf38bvarqa";
containerdVersion = "1.7.20-k3s1";
containerdSha256 = "12ihr3z8vcglv5b0v9ris29zkkkdvjbcp3bf7ym71a0xdbg83s8i";
criCtlVersion = "1.31.0-k3s2";
}
2 changes: 1 addition & 1 deletion pkgs/applications/networking/cluster/k3s/builder.nix
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ let
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"
to_replace="/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
Expand Down
10 changes: 10 additions & 0 deletions pkgs/applications/networking/cluster/k3s/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,14 @@ in
];
}
) extraArgs;

k3s_1_31 = common (
(import ./1_31/versions.nix)
// {
updateScript = [
./update-script.sh
"31"
];
}
) extraArgs;
}
8 changes: 7 additions & 1 deletion pkgs/applications/networking/cluster/k3s/update-script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,13 @@ CONTAINERD_VERSION=$(grep github.com/containerd/containerd ${FILE_GO_MOD} \
CONTAINERD_SHA256=$(nix-prefetch-url --quiet --unpack \
"https://github.com/k3s-io/containerd/archive/refs/tags/v${CONTAINERD_VERSION}.tar.gz")

CRI_CTL_VERSION=$(grep github.com/kubernetes-sigs/cri-tools ${FILE_GO_MOD} \
# The repository of "cri-tools" changes for 1.31.x, this can likely be removed in future releases
if [ "$MINOR_VERSION" -gt 30 ]; then
CRI_CTL_REPO=sigs.k8s.io
else
CRI_CTL_REPO=github.com/kubernetes-sigs
fi
CRI_CTL_VERSION=$(grep "$CRI_CTL_REPO/cri-tools" ${FILE_GO_MOD} \
| head -n1 | awk '{print $4}' | sed -e 's/"//g' -e 's/^v//')

setKV () {
Expand Down
13 changes: 7 additions & 6 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -31076,12 +31076,13 @@ with pkgs;

jwm-settings-manager = callPackage ../applications/window-managers/jwm/jwm-settings-manager.nix { };

inherit (callPackage ../applications/networking/cluster/k3s {
buildGoModule = buildGo121Module;
go = go_1_21;
}) k3s_1_28 k3s_1_29;
inherit (callPackage ../applications/networking/cluster/k3s { }) k3s_1_30;
k3s = k3s_1_30;
inherit (callPackage ../applications/networking/cluster/k3s { })
k3s_1_28
k3s_1_29
k3s_1_30
k3s_1_31
;
k3s = k3s_1_31;

k3sup = callPackage ../applications/networking/cluster/k3sup { };

Expand Down

0 comments on commit a779daa

Please sign in to comment.