mirror of
https://github.com/deuxfleurs-org/garage.git
synced 2026-07-26 07:58:14 +00:00
[nix-improvements] use kaniko and manifest-tools from nixpkgs, simplify
This commit is contained in:
@@ -6,8 +6,6 @@ let
|
||||
pkgs = import pkgsSrc {
|
||||
inherit system;
|
||||
};
|
||||
kaniko = (import ./nix/kaniko.nix) pkgs;
|
||||
manifest-tool = (import ./nix/manifest-tool.nix) pkgs;
|
||||
winscp = (import ./nix/winscp.nix) pkgs;
|
||||
in
|
||||
{
|
||||
@@ -18,10 +16,10 @@ in
|
||||
# The shell used for all CI jobs (along with devShell)
|
||||
ci = pkgs.mkShell {
|
||||
nativeBuildInputs = with pkgs; [
|
||||
kaniko
|
||||
manifest-tool
|
||||
winscp
|
||||
|
||||
kaniko
|
||||
manifest-tool
|
||||
awscli2
|
||||
file
|
||||
s3cmd
|
||||
@@ -123,15 +121,6 @@ in
|
||||
# A shell for refreshing caches
|
||||
cache = pkgs.mkShell {
|
||||
shellHook = ''
|
||||
function refresh_toolchain {
|
||||
pass show deuxfleurs/nix_priv_key > /tmp/nix-signing-key.sec
|
||||
nix copy -j8 \
|
||||
--to 's3://nix?endpoint=garage.deuxfleurs.fr®ion=garage&secret-key=/tmp/nix-signing-key.sec' \
|
||||
$(nix-store -qR \
|
||||
$(nix-build -j8 --no-build-output --no-out-link nix/toolchain.nix))
|
||||
rm /tmp/nix-signing-key.sec
|
||||
}
|
||||
|
||||
function refresh_cache {
|
||||
pass show deuxfleurs/nix_priv_key > /tmp/nix-signing-key.sec
|
||||
for attr in clippy.amd64 test.amd64 pkgs.{amd64,i386,arm,arm64}.release; do
|
||||
@@ -143,17 +132,6 @@ in
|
||||
done
|
||||
rm /tmp/nix-signing-key.sec
|
||||
}
|
||||
|
||||
function refresh_flake_cache {
|
||||
pass show deuxfleurs/nix_priv_key > /tmp/nix-signing-key.sec
|
||||
for attr in packages.x86_64-linux.default devShells.x86_64-linux.default; do
|
||||
echo "Updating cache for ''${attr}"
|
||||
nix copy -j8 \
|
||||
--to 's3://nix?endpoint=garage.deuxfleurs.fr®ion=garage&secret-key=/tmp/nix-signing-key.sec' \
|
||||
".#''${attr}"
|
||||
done
|
||||
rm /tmp/nix-signing-key.sec
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user