ryansch / docker-unifi-rpi

Unifi Controller for Raspberry Pi 3+ and x86
https://hub.docker.com/r/ryansch/unifi-rpi/
347 stars 42 forks source link

Docker tag naming convention to differentiate official and beta versions #72

Closed rasmuslp closed 8 months ago

rasmuslp commented 3 years ago

Would it be possible to mark beta versions as such in the Docker image tag?

With semantic versioning - which it looks like the Unifi Controller already follows to some degree - it would become something like 6.1.20-beta instead of just 6.1.20. The added bonus being that the stable version would be identifiable as the highest 'pure' version number.

My use case: I use whats-up-docker to monitor containers for image updates. With that, I can specify a regular expression that is used to match on the tags (e.g. ^\d+\.\d+\.\d+$). However, that doesn't work here.

ryansch commented 3 years ago

You should be able to monitor for a shorter tag. For the 6.1 series, there hasn't been a stable release yet so there isn't a 6.1 tag.

rasmuslp commented 3 years ago

Ah I see, so stable releases can be tracked as a x.y tags. I'll give it a try with ^\d+\.\d+$, but I'm unsure if what's up docker can correctly detect that an existing tag changes. I believe it 'simply' lists all tags and checks if the semantic version is higher than the currently running version.

ryansch commented 3 years ago

Hopefully that will make it ignore 'full versions' and then the notifications will work.

I based the tagging strategy off of a lot of the official images I use at work.

rasmuslp commented 3 years ago

Unfortunately, that doesn't work, as what's up docker doesn't handle mutable tags. At least not at the moment, but I gather from this https://github.com/fmartinou/whats-up-docker/issues/22 that it's a planned feature.

ryansch commented 3 years ago

@rasmuslp Is there any reason you can't use latest?

Edit: Only official releases are ever tagged with latest. Never testing, release candidate, etc.

rasmuslp commented 3 years ago

I manage my containers with Ansible, where I specify the exact versions of images. I do this to get a history in git, of what has been running where, and so that I can easily revert to a previously known good image, should a problem occur.

Being able to differentiate official and rc releases would allow me to specify a broad version range like ^\d+\.\d+\.\d+$ - for use in https://github.com/fmartinou/whats-up-docker - that would work for all future versions, assuming the versioning convention doesn't change of course.