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

VERSION in Makefile resolved to Git hash instead of tag #190

Open
mloskot opened this issue Sep 21, 2024 · 0 comments
Open

VERSION in Makefile resolved to Git hash instead of tag #190

mloskot opened this issue Sep 21, 2024 · 0 comments

Comments

@mloskot
Copy link
Contributor

mloskot commented Sep 21, 2024

The git rev-parse --short HEAD below resolves to Git hash

go-httpbin/Makefile

Lines 3 to 4 in 34a21a3

VERSION ?= $(shell git rev-parse --short HEAD)
DOCKER_TAG ?= mccutchen/go-httpbin:$(VERSION)

Shouldn't the VERSION be based on Git tag, that is, git describe --tags --abbrev=0?

This makes me wonder, is this VERSION actually used for the image tagging?

Perhaps Docker images are tagged following this instruction?

Use `VERSION` to override the tag value
make imagepush VERSION=v1.2.3

If my understanding is correct and there is room for improvement indeed, I can propose PR.

mloskot added a commit to mloskot/go-httpbin that referenced this issue Sep 21, 2024
Refs:
- mccutchen#188
- mccutchen#190

Signed-off-by: Mateusz Łoskot <mateusz@loskot.net>
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

1 participant