Update docker?

Associate
Joined
24 Jul 2009
Posts
2,264
Location
-
I installed docker using the command sudo apt get install docker.io docker-compose -y at the start of the year on Debian (must have followed a YouTube guide) and have since learned that this is an old way of installing it as it's on version 20.10.24 of docker and 1.29.2 of docker compose.

I have many services running in docker now and I want to update docker. How can I do this without losing the services/containers I have running?
 
Last edited:
Updates and upgrade for Debian are sudo apt update/upgrade. I have portainer installed to manually restart containers of needed.

Updating containers isn't a problem. It's just the docker version as it's 4 years old.

The newer way to install is 'sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin' but I don't want to run this if it'll mess up my current docker.
 
Last edited:
Thanks. I'll make backups and see where I get. According to the official install. I need to remove docker.io and docker-compose before installing the current way.
 
Back
Top Bottom