Skip to content

alpine carry its own hash#3650

Merged
deitch merged 1 commit intolinuxkit:masterfrom
deitch:alpine-hash
May 6, 2021
Merged

alpine carry its own hash#3650
deitch merged 1 commit intolinuxkit:masterfrom
deitch:alpine-hash

Conversation

@deitch
Copy link
Collaborator

@deitch deitch commented May 2, 2021

Signed-off-by: Avi Deitcher avi@deitcher.net

- What I did

Small change: have linuxkit/alpine calculate and carry its own hash, and use it from makefile, rather than calculating it in the Makefile. As a nice side effect, it allows us to be working inside any linuxkit/alpine image and know precisely what tag ran it.

Also, docker build sets TARGETARCH for us, which gets rid of a few lines in the Makefile

Finally, if we ever change how we calculate it, that change will be inherent inside the image build itself

- How I did it

Move some logic from tools/alpine/Makefile to tools/alpine/Dockerfile, and then change Makefile to consume it.

- How to verify it

Run it.

- Description for the changelog

linuxkit/alpine carries its own calculated hash tag with it.

Signed-off-by: Avi Deitcher <avi@deitcher.net>
@deitch deitch merged commit ceef6b1 into linuxkit:master May 6, 2021
@deitch deitch deleted the alpine-hash branch May 6, 2021 17:11
@deitch
Copy link
Collaborator Author

deitch commented May 6, 2021

Thanks @dave-tucker

@rn
Copy link
Member

rn commented May 6, 2021

I personally have a strong preference on having the details in the git commit message rather than the PR summary. I can do git show <hash> and get the explanation. but here i only get the summary line and the details are on some web page. Might be a bit old fashioned...

@deitch
Copy link
Collaborator Author

deitch commented May 6, 2021

I don't understand Rolf. To what do you refer, the git commit message vs PR?

@rn
Copy link
Member

rn commented May 6, 2021

git show 1e99ba3dcee3
commit 1e99ba3dcee3cfffe53e1a0f13cdf4a61bd4874b
Author: Avi Deitcher <avi@deitcher.net>
Date:   Sun May 2 19:44:39 2021 +0300

    alpine carry its own hash

    Signed-off-by: Avi Deitcher <avi@deitcher.net>

diff --git a/tools/alpine/Dockerfile b/tools/alpine/Dockerfile

has none of the details you mentions above, like

Also, docker build sets TARGETARCH for us, which gets rid of a few lines in the Makefile

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

Successfully merging this pull request may close these issues.

3 participants

Comments