diff options
author | Alex <alex@adnab.me> | 2022-09-27 11:55:49 +0200 |
---|---|---|
committer | Alex <alex@adnab.me> | 2022-09-27 11:55:49 +0200 |
commit | 2197753dfdb25944e55c25d911ae6d14b8506c4d (patch) | |
tree | 74e6273bc6c520e2546ba31a8f86bb44e0be69b2 /shell.nix | |
parent | 3f95a0f717885ed2e0ac6ec6cb745daad0d572fd (diff) | |
parent | d104ae871170e5d1dac644921815bcce8496f23c (diff) | |
download | garage-2197753dfdb25944e55c25d911ae6d14b8506c4d.tar.gz garage-2197753dfdb25944e55c25d911ae6d14b8506c4d.zip |
Merge pull request 'Add step to generate multi-arch Docker container in CI' (#393) from multi-arch-container into mainv0.8.0-rc1
Reviewed-on: https://git.deuxfleurs.fr/Deuxfleurs/garage/pulls/393
Diffstat (limited to 'shell.nix')
-rw-r--r-- | shell.nix | 30 |
1 files changed, 30 insertions, 0 deletions
@@ -10,6 +10,7 @@ let overlays = [ cargo2nixOverlay ]; }; kaniko = (import ./nix/kaniko.nix) pkgs; + manifest-tool = (import ./nix/manifest-tool.nix) pkgs; winscp = (import ./nix/winscp.nix) pkgs; in @@ -84,6 +85,34 @@ function to_docker { --verbosity=debug } +function multiarch_docker { + manifest-tool push from-spec <(cat <<EOF +image: dxflrs/garage:''${CONTAINER_TAG} +manifests: + - + image: dxflrs/arm64_garage:''${CONTAINER_TAG} + platform: + architecture: arm64 + os: linux + - + image: dxflrs/amd64_garage:''${CONTAINER_TAG} + platform: + architecture: amd64 + os: linux + - + image: dxflrs/386_garage:''${CONTAINER_TAG} + platform: + architecture: 386 + os: linux + - + image: dxflrs/arm_garage:''${CONTAINER_TAG} + platform: + architecture: arm + os: linux +EOF + ) +} + function refresh_index { aws \ --endpoint-url https://garage.deuxfleurs.fr \ @@ -113,6 +142,7 @@ function refresh_index { nativeBuildInputs = [ pkgs.awscli2 kaniko + manifest-tool ]; }; } |