docker restart container code example
Example 1: docker stop all
docker stop $(docker ps -a -q)
docker rm $(docker ps -a -q)
Example 2: how to restart docker linux
$ sudo systemctl start docker
Example 3: docker restart
sudo systemctl restart docker
Example 4: how to start docker
systemctl start docker.service
#(OR)
systemctl start docker
# it will start docker
Example 5: docker run restart on boot
$ docker run -d --restart unless-stopped <image>
Example 6: docker restart container
docker restart CONTAINER_ID