dockerTools.buildImageWithNixDb: simplifications and switch to closure info#49414
dockerTools.buildImageWithNixDb: simplifications and switch to closure info#49414nlewo merged 1 commit intoNixOS:masterfrom
Conversation
|
@GrahamcOfBorg test docker-tools |
|
Success on aarch64-linux Attempted: tests.docker-tools No partial log is available. |
|
Success on x86_64-linux (full log) Attempted: tests.docker-tools Partial log (click to expand)
|
|
If I am correct we already rely on Nix 2 features so I don't see any reason why not. |
There was a problem hiding this comment.
contents can be a list of derivations. It can also be one single derivation that defines the docker image layer.
See this:
nixpkgs/pkgs/build-support/docker/default.nix
Line 268 in 2f9fc89
There was a problem hiding this comment.
Would have been nice to have typed Nix here :)
I fixed this. Thanks!
There was a problem hiding this comment.
Where is the closure?
There was a problem hiding this comment.
The closure is copied by the buildImage function. This copy was needed to do the --check-contents at the layer level. This is no longer required (with Nix 2.0) to initialize correctly the database.
8e70baa to
8a4cb4a
Compare
|
@FRidh yes, it seems now we can. In fact, I already submitted this PR 6 months back but it was too early to rely on Nix 2 features. |
8a4cb4a to
abe49bf
Compare
…eInfo Since Nix 2 is now the stable Nix version, we can use closureInfo which simplifies the Nix database initialisation (size and hash are included in the "dump").
abe49bf to
c12f756
Compare
Since Nix 2 is now the stable Nix version, we can use closureInfo
which simplifies the Nix database initialisation (size and hash are
included in the "dump").
Things done
sandboxinnix.confon non-NixOS)nix-shell -p nox --run "nox-review wip"./result/bin/)nix path-info -Sbefore and after)