Conversation
| tags: | | ||
| type=ref,event=branch | ||
| # set latest tag for main branch | ||
| type=raw,value=latest,enable={{is_default_branch}} |
There was a problem hiding this comment.
I'm suspicious about using is_default_branch. We may change the default branch at some point, not realizing it would affect the image tag. Or maybe I'm not understanding the situation.
There was a problem hiding this comment.
I can comment that better in the README. Scheduled builds only build the default branch, So we will want to update the default branch to whatever the latest version is. Alternatively, we could always update main whenever we update the latest branch or make a new branch. Which theoretically we should have already been doing, but haven't
There was a problem hiding this comment.
@jason-jackson Check my understanding here. It looks like this will run at 1:07 am on the 8th day of each month, and I think you said scheduled GitHub Actions only run on the default branch of the repo. It will build the docker image and then tag it (1) as latest if it's the default branch (won't it always be?) and (2) tag it with the branch name (e.g. 8.1).
Is that correct?
There was a problem hiding this comment.
That is correct. Currently scheduled build was for 1am on the 8th day of the month, but due to warning, I pushed it out a few minutes.
It might not always be pushed to the default branch. It will create a tag for every push to any branch with the branch name as the tag (with certain characters changed if needed). The on has both push and schedule so it will do it for both of them. See https://hub.docker.com/r/silintl/php8.
Changes:
Note: It might be easier to view without cleanup here.