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
Initial support for reproducible builds #3255
Conversation
When creating files for the "intermediate" tar ball, fix the ModTime. This reduces the difference between LinuxKit images build from identical inputs. Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
Currently 'docker export' is used to convert a linuxkit entry in the YAML file to a tar file of the root filesystem. This process creates a number of files and directories which have the timestamp of when the 'docker export' is run. Fix 'em up. Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
Sort list of capabilities that go into config.json. Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
Sort the list of mount points by destination. This makes the list deterministic for reproducible builds and also ensures that, e.g., the mount for /dev happens before the mount for /dev/pts. Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
Test the 'tar' and 'kernel+initrd' formats for now. Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
|
This is rather nice! Is there concern that the modtime now is just the timestamp that lkt open sourced? Might we want to have a cmdline option to set the date-time as an input, with a default for that time, and maybe an option that says, "now"? E.g. Or |
|
Yeah, was considering making the timestamp configurable. But rather than via the commandline, we should probably support this proposal and make it configurable via the environment variable |
|
If that’s where it’s going as a standard, I guess. I like command line options as they are explicit. But not going to be a stickler about it. :-) |
|
LGTM as a first pass. I think setting all times to the git commit time of the linuxkit build itself might also be a reasonable option in future, but a static time is fine for now. |
|
I like the idea of using the git commit time as the default. That way it is different for different |
This PR adds initial support for reproducible
linuxkit builds (wip #2813).Currently, the
tar,tar-kernel-initrd,docker, andkernel+initrdoutput formats support reproducible builds and tests fortarandkernel+initrdare added with this PR.