-
-
Notifications
You must be signed in to change notification settings - Fork 15.2k
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
dockerTools: use makeOverridable for buildImage family of functions #208944
dockerTools: use makeOverridable for buildImage family of functions #208944
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not really familiar with the override mecanism, but this looks legit to me.
I think we should do it on all buildImage*
functions: it's missing for the buildImageWithNixDB
.
I didn't do it on |
bd0dec0
to
b04d3d4
Compare
@ofborg test docker-tools Regretting enabling the redis tests way back when. |
Oh |
|
this allows nix users to modify existing images without having to rely on container image inheritance mechanisms via fromImage
5e67c5c
to
680dfee
Compare
Something I would have been happy to use in my code recently so +1 |
How are the tests broken? |
Appears to work though if I give the test machine more disk space. |
This may or may not cause some sort of (caching?) breakage in Arion, per hercules-ci/arion#217 |
That's interesting. If you look at the definition of
|
Possible fix: Haven't tested the integration with arion, but I'd expect that to work. |
Awesome love it when someone's 10 minutes ahead of me. Will review. |
Description of changes
This may be a bit naive as I haven't really dug into the internals of
dockerTools
before - but to me we're missing a trick by not making the resulting images overridable. UsingmakeOverridable
allowsdockerTools
-based images to be customized at the nix-level, which has numerous advantages over using image inheritance viafromImage
, e.g.config
can actually be extended rather than wholesale-replacedbuildImage
haspassthru.buildArgs
but it is unique in this and is a bit more awkward to use than.override
.Have built
dockerTools.examples
on x86_64 linux and verified this causes no rebuilds.Things done
sandbox = true
set innix.conf
? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)nixos/doc/manual/md-to-db.sh
to update generated release notes