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

minikube binaries differ for every build #3005

Closed
bmwiedemann opened this issue Jul 23, 2018 · 1 comment
Closed

minikube binaries differ for every build #3005

bmwiedemann opened this issue Jul 23, 2018 · 1 comment

Comments

@bmwiedemann
Copy link
Contributor

BUG REPORT:

Environment: Linux

Minikube version : 0.27.0

  • OS : openSUSE-Tumbleweed

What happened:
When building the minikube openSUSE package, there are differences between every build.

build-compare's pkg-diff reports:

/usr/bin/minikube differs in ELF section .rodata
@@ -259384,10 +259384,10 @@
  14d6330 00044000 00000000 00000000 00000000  ..@.............
  14d6340 2f757372 2f6c6962 36342f67 6f2f312e  /usr/lib64/go/1.
  14d6350 31300000 00000000 00000000 00000000  10..............
- 14d6360 32303138 2d30372d 32315430 363a3532  2018-07-21T06:52
- 14d6370 3a33335a 00000000 00000000 00000000  :33Z............
- 14d6380 32303138 2d30372d 32315430 363a3532  2018-07-21T06:52
- 14d6390 3a33335a 00000000 00000000 00000000  :33Z............
+ 14d6360 32303138 2d30372d 32315430 363a3533  2018-07-21T06:53
+ 14d6370 3a35355a 00000000 00000000 00000000  :55Z............
+ 14d6380 32303138 2d30372d 32315430 363a3533  2018-07-21T06:53
+ 14d6390 3a35355a 00000000 00000000 00000000  :55Z............

What you expected to happen:
The build process should produce bit-identical binaries. E.g. use the $SOURCE_DATE_EPOCH environment variable instead of the current date as documented in
https://wiki.debian.org/ReproducibleBuilds/TimestampsProposal#Go

How to reproduce it (as minimally and precisely as possible):

osc checkout openSUSE:Factory/minikube
cd $_
osc build
@dlorenc
Copy link
Contributor

dlorenc commented Jul 23, 2018

Hmm, looks like this is coming from the build date we inject here: https://github.com/kubernetes/minikube/blob/master/hack/get_k8s_version.py#L65

Are you interested in changing this up? I'm not quite sure what the best general fix is.

dlorenc pushed a commit that referenced this issue Jul 24, 2018
in order to make builds reproducible.
See https://reproducible-builds.org/ for why this is good
and https://reproducible-builds.org/specs/source-date-epoch/
for the definition of this variable.

Fixes #3005
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants