The metadata action automatically adds the container image tag latest when using type=ref,event=tag. This would result in any newly pushed tag receiving the latest tag. As we don't want this for rc tags, we should change the tags input.
Instead, type=semver,pattern={{ version }}. This way, the container image will receive the semver as tag. As we now no longer tag anything with latest, we need to add an input of type=raw that checks if we're tagging anything in the current stable version (0.1.*).
Finally, add an rc container image tag when the git tag contains '-rc.'. This way, people can test rc's by specifying the :rc tag.
The metadata action automatically adds the container image tag latest when using type=ref,event=tag. This would result in any newly pushed tag receiving the latest tag. As we don't want this for rc tags, we should change the tags input.
Instead, type=semver,pattern={{ version }}. This way, the container image will receive the semver as tag. As we now no longer tag anything with latest, we need to add an input of type=raw that checks if we're tagging anything in the current stable version (0.1.*).
Finally, add an rc container image tag when the git tag contains '-rc.'. This way, people can test rc's by specifying the :rc tag.