Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix hardcoded value in local-image-test #1545

Merged
merged 1 commit into from
Dec 15, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions tools/public/local-image-test.nix
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,15 @@ writeShellScriptBin "local-image-test" ''
IMAGE_TAG=$(nix eval .#$1.imageTag --raw)
IMAGE_NAME=$(nix eval .#$1.imageName --raw)

nix run .#image.copyTo \
nix run .#$1.copyTo \
docker-daemon:''${IMAGE_NAME}:''${IMAGE_TAG}

# Ensure that the image has minimal closure size.
# TODO(aaronmondal): The default allows 10% inefficiency. Since we control all
# our images fully we should enforce 0% inefficiency. At
# the moment this breaks lre-cc.
CI=1 ${dive}/bin/dive \
''${IMAGE_NAME}:''${IMAGE_TAG} \
--highestWastedBytes=0
''${IMAGE_NAME}:''${IMAGE_TAG}

# TODO(aaronmondal): Keep monitoring this for better solutions to ratelimits:
# https://github.com/aquasecurity/trivy-action/issues/389
Expand Down