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

Docker version tag for major/minor version branch #82

Closed
ocean90 opened this issue Apr 3, 2023 · 3 comments
Closed

Docker version tag for major/minor version branch #82

ocean90 opened this issue Apr 3, 2023 · 3 comments
Labels
docker Docker builds and images github_actions Pull requests that update GitHub Actions code

Comments

@ocean90
Copy link

ocean90 commented Apr 3, 2023

Right now the Docker images are only available via the latest and the specific version tags. It would be helpful to be able to only define axllent/mailpit:v1.5 which would pull the latest version of the 1.5 branch. That would be 1.5.4 at the moment.

It seems like this only needs a change to

tags: axllent/mailpit:latest,axllent/mailpit:${{ github.ref_name }}

Maybe the docker/metadata-action action will be useful: https://github.com/docker/metadata-action#typesemver

@axllent
Copy link
Owner

axllent commented Apr 3, 2023

Thanks for the suggestion, this is a good idea. I think that the docker/metadata-action is probably an overkill as it is designed to also push images (I just need to work out that the major.minor version is), so I'm going to try another simpler action first. Assuming this works (you never know until you try), the next release should include a mailpit:v1.5 tag 👍 I will leave this open until the next release (which are fairly regular).

@axllent axllent added github_actions Pull requests that update GitHub Actions code docker Docker builds and images labels Apr 3, 2023
@ocean90
Copy link
Author

ocean90 commented Apr 3, 2023

Sounds good! I don't think it will be push stuff as it only provides an output for the metadata which can be used by the push action. The readme has a good example for this.

@axllent
Copy link
Owner

axllent commented Apr 4, 2023

I've tested this on a separate testing repo and the action I am using to detect the major/minor version is working as expected. Given there are no current changes it may be a while before another release, so in the interim I have manually pushed a v1.5 tag (identical currently to v1.5.4) so you can start using that already if you like. When newer v1.5.* releases are created, the v1.5 tag will be updated, then v.16 will get added and updated etc when the release tags reach v1.6.* etc.

I'll close this ticket as it is effectively done now (just waiting for more releases). Thanks again for the suggestion.

@axllent axllent closed this as completed Apr 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docker Docker builds and images github_actions Pull requests that update GitHub Actions code
Projects
None yet
Development

No branches or pull requests

2 participants