Skip to content

Release-tagged container images are overwritten on each push to main #551

@daniel-weisse

Description

@daniel-weisse

The Build And Push Dock Image action, which runs on each push to main, tags the images pushed with the latest release version.
For example, the commit fa55c3a (which was pushed after v0.1.1 was published) built and published a new container image tagged as 0.1.1, overriding the image originally published for the v0.1.1 release.

This can cause problems for people relying simply on the tag of the container image.
For people pinning the image digest this only causes some minor annoyances, e.g. because tools like renovate will try to upgrade the pinned digest even though the image tag hasn't changed.

A possible fix could be using a pseudo-version in the version file on main, and only setting the "real" version for the commit a release is published on.

Alternatively, the GitHub action responsible for publishing the image could only set the version tag when the action is run for a release.
Possible options for this include using an on-release event trigger, or manually running the workflow and adding a user input to control tagging of the final image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions