Home > Software design >  How do I stop them from starting automatically without deleting the containers?
How do I stop them from starting automatically without deleting the containers?

Time:11-04

I built some docker images from a YAML file with the command docker-compose up -d a few days ago, now every time I restart my Ubuntu a bunch of containers start automatically. How do I stop them from starting automatically without deleting the containers?

CodePudding user response:

Your problem is the restart:always line(s). restart: unless-stopped could help you.

You can update them like this:

 docker update --restart unless-stopped <name-of-your-container>
  • Related