Docker: Difference between revisions
Content added Content deleted
m (→NGINX: auto restart) |
m (→NGINX: auto restart) |
||
Line 89: | Line 89: | ||
Run nginx docker image with auto Restart on reboot option |
Run nginx docker image with auto Restart on reboot option |
||
docker run --name nginx -p 80:80 -d -v ~/docker-nginx/html:/usr/share/nginx/html --restart unless-stopped nginx |
docker run --name nginx -p 80:80 -d -v ~/docker-nginx/html:/usr/share/nginx/html --restart unless-stopped nginx |
||
Docker currently has four restart policies[https://blog.codeship.com/ensuring-containers-are-always-running-with-dockers-restart-policy/]: |
|||
no |
|||
on-failure |
|||
unless-stopped |
|||
always |
|||
;Multiple Instances |
;Multiple Instances |