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

ci(build-deploy.yml): correctly set Docker latest tag only on release versions #1695

Merged
merged 1 commit into from
Mar 7, 2023

Conversation

mion00
Copy link
Contributor

@mion00 mion00 commented Mar 7, 2023

The default configuration for the docker/metadata-action@v4.3.0 is to tag with latest whenever there is a git tag, but this is not compatible with our use of pre-release tags (alpha, beta, etc..).
This versions should still be tagged, just not with latest.

Description

  • Tag with latest the git tags that do not have a "pre-release" component in the end (e.g. 3.0.0)
  • Avoid tagging with latest the git tag that have a "pre-release" component in the end (e.g. 3.0.0b1)
  • If no git tag, fallback to using branch or PR name as tag

@mion00
Copy link
Contributor Author

mion00 commented Mar 7, 2023

May I suggest pushing a beta version out sooner or later? That way we could test the whole deploy pipeline (if everything goes to plan, we should avoid breaking existing users installations).
With this fix we won't touch the latest tag in Docker using a pre-release tag, so existing users will not pull down the beta by accident. Also pip installation automatically skip beta versions (if I read the docs correctly).

@acockburn
Copy link
Member

Definitely - it should be as simple as tagging the current master branch to make a release, it will have zero changes and wouldn't;t contain any dangerous breaking code but would exercise the release process. Afterwards it will be easy to clean up the releases and any artifacts that make it out to PyPi or Docker by mistake. Sound like a plan?

@acockburn acockburn merged commit d677bae into AppDaemon:dev Mar 7, 2023
@mion00
Copy link
Contributor Author

mion00 commented Mar 7, 2023

Definitely - it should be as simple as tagging the current master branch to make a release, it will have zero changes and wouldn't;t contain any dangerous breaking code but would exercise the release process. Afterwards it will be easy to clean up the releases and any artifacts that make it out to PyPi or Docker by mistake. Sound like a plan?

If you tag the current master I think nothing will happen. It doesn't contain the github workflow files, since they are all in the dev branch. Maybe you meant to tag the dev branch?

@mion00 mion00 deleted the ci/docker_latest_tag branch March 7, 2023 18:09
@acockburn
Copy link
Member

You make a good point ;)

ok well I’ll do a release in a day or two of whatever is in dev and call it a beta

@acockburn
Copy link
Member

acockburn commented Mar 19, 2023 via email

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.

2 participants