lol

Merge pull request #304318 from superherointj/fluxcd-update-script-use-sri-hash

fluxcd: use SRI hash in update script

authored by

superherointj and committed by
GitHub
7d7fedce 8c874a07

+4 -2
+2 -2
pkgs/applications/networking/cluster/fluxcd/default.nix
··· 8 8 9 9 let 10 10 version = "2.2.3"; 11 - sha256 = "12rrai56hl86213lsi8i4qrah0v7a36nks38g5373imyl9g497ym"; 12 - manifestsSha256 = "1hmzmzijpx49hh2ykv7vw3jp02dxr4qn3r1dma56g7b4nbk7aa8x"; 11 + sha256 = "sha256-1Z9EXqK+xnFGeWjoac1QZwOoMiYRRU1HEAZRaEpUOYs="; 12 + manifestsSha256 = "sha256-HSl15rJknWeKqi3kYTHJvQlw5eD77OkFhIn0K+Ovv8I="; 13 13 14 14 manifests = fetchzip { 15 15 url =
+2
pkgs/applications/networking/cluster/fluxcd/update.sh
··· 12 12 13 13 if [ ! "$OLD_VERSION" = "$LATEST_VERSION" ]; then 14 14 SHA256=$(nix-prefetch-url --quiet --unpack https://github.com/fluxcd/flux2/archive/refs/tags/${LATEST_TAG}.tar.gz) 15 + SHA256=$(nix hash to-sri --type sha256 $SHA256) 15 16 SPEC_SHA256=$(nix-prefetch-url --quiet --unpack https://github.com/fluxcd/flux2/releases/download/${LATEST_TAG}/manifests.tar.gz) 17 + SPEC_SHA256=$(nix hash to-sri --type sha256 $SPEC_SHA256) 16 18 17 19 setKV () { 18 20 sed -i "s|$1 = \".*\"|$1 = \"${2:-}\"|" "${FLUXCD_PATH}/default.nix"