refactor(docker): use rec for imageName in image files
All checks were successful
Discord / discord commits (push) Has been skipped
All checks were successful
Discord / discord commits (push) Has been skipped
This commit is contained in:
parent
82a05091a5
commit
559d9e0fbd
2 changed files with 4 additions and 3 deletions
|
@ -1,8 +1,8 @@
|
||||||
pkgs:
|
pkgs:
|
||||||
pkgs.dockerTools.pullImage {
|
pkgs.dockerTools.pullImage rec {
|
||||||
imageName = "some/image/name";
|
imageName = "some/image/name";
|
||||||
imageDigest = "";
|
imageDigest = "";
|
||||||
sha256 = "";
|
sha256 = "";
|
||||||
finalImageName = "";
|
finalImageName = imageName;
|
||||||
finalImageTag = "latest";
|
finalImageTag = "latest";
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,7 +25,8 @@ writeShellApplication {
|
||||||
if [[ "$CURRENT_DIGEST" != "$NEW_DIGEST" ]]; then
|
if [[ "$CURRENT_DIGEST" != "$NEW_DIGEST" ]]; then
|
||||||
echo -e "• $output:\n $CURRENT_DIGEST\n → $NEW_DIGEST\n"
|
echo -e "• $output:\n $CURRENT_DIGEST\n → $NEW_DIGEST\n"
|
||||||
PREFETCH=$(nix-prefetch-docker "$IMAGE" "$TAG")
|
PREFETCH=$(nix-prefetch-docker "$IMAGE" "$TAG")
|
||||||
echo -e "pkgs:\npkgs.dockerTools.pullImage $PREFETCH" > "$FILE"
|
echo -e "pkgs:\npkgs.dockerTools.pullImage rec $PREFETCH" > "$FILE"
|
||||||
|
sed -i 's/finalImageName.*/finalImageName = imageName;/' "$FILE"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
|
|
Loading…
Reference in a new issue