I run a home docker server, for the most part it was a “set it and forget” sort of setup. Occasionally I update the docker images and always have to remind myself of the steps involved as I don’t do it often enough. I built my initial docker setup following most of this guide.
Here are the steps I take to update my docker images and Ubuntu server.
Sudo apt-get update
- Always a good idea to install server updates first.
Docker-compose -f ~/docker/docker-compose.yml down
- You need to run this command from the folder where your docker compose file is located. This will force a shutdown of all of your docker containers included in your compose file.
Docker-compose pull
- This command will pull down the new docker container images from your compose repository.
Docker-compose -f ~/docker/docker-compose.yml up
- This command forces all of your docker container images to start up again.
- Check on the status of your docker containers by running
docker ps -a
. - Restart your server, if necessary, with the
shutdown -r
command.