As far as I can tell, the auto_tag
feature silently ignores semver parsing failure and returns latest
instead.
From the docs
Please note that auto-tagging is intentionally simple and opinionated. We are not accepting pull requests at this time to further customize the logic
From Issue #237
I’m not a big fan of changing the auto tag behavior, as brad said it’s pretty simple intentionally.
Though I acknowledge all that would someone be so kind as to clarify why the current implementation behaves like this?
Of course, it causes problems to us because our staging environment depends on (ie. pulls) the latest
images so whenever a not semver tag hits the repository, auto_tag
eventually moves the latest
tag to another arbitrary image in the repository.
IMHO it would be better to make the build fail or use the provided tag as is.