`docker_manager` should go first

On the upgrade page, it’s always a drag having to wait for all plugins to check for new updates, and end up with docker_manager needing to be upgraded first. Is there a way to make this happen, that before checking for any new version, the upgrade system first checks whether docker_manager needs to be updated? It would save a lot of HTTP requests and some time for admins who tend to spend more time than necessary performing upgrades.

12 Likes

Sounds like a good idea to me, I’m sure it would be pr-welcome if someone would like to work on it :slight_smile:

7 Likes

An excellent idea. Always having to scroll down to check it first.

5 Likes

I decided to give this a try. PR here: https://github.com/discourse/docker_manager/pull/100

That will always put docker_manager second in the list, after discourse itself:

Edit: That’s merged :tada:

14 Likes

Thank you @david! Does it skip the checks for other plugins if docker_manager is not up-to-date?

3 Likes

No it doesn’t skip them, but it means the docker_manager one happens first. An admin can then click the docker_manager update button immediately, even while the other plugins are loading.

I think it’s still useful to see whether other plugins have updates available, even if you can’t install them immediately?

5 Likes

Usually when you see a new docker_manager release it’s because a new Discourse release was announced in your admin notifications, so you would most probably do 1. upgrade docker_manager, then 2. upgrade all, 80 to 90% of the time.

When you want to check for a single plugin you scroll down anyway. I’m simply thinking about wasted resources. After some years of upgrades, across thousands of instances, that would make a lot of saved resources.

I suppose a middle ground would be to kill the check requests when the docker_manager upgrade button is clicked. But I would expect that simply not checking when this plugin is out-of-date would be the most sensible – I do not have stats, maybe you do.

4 Likes

We don’t use docker_manager on our managed hosting, so no stats I’m afraid.

But ‘checking for updates’ is a super cheap thing to do. Under the covers, docker_manager is doing a git remote update on every plugin. It only pulls across the changes since the last check, so the data transfer should be tiny.

5 Likes

This topic was automatically closed after 6 days. New replies are no longer allowed.