Skip to content
This repository has been archived by the owner on Jun 22, 2018. It is now read-only.

Commit

Permalink
added restart: on-failure parameter to compose config examples
Browse files Browse the repository at this point in the history
  • Loading branch information
kawaii committed Dec 3, 2017
1 parent 5e294b9 commit 8cc2901
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docker-compose.yml.mariadb.example
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ services:
- frontend
ports:
- '8080:80'
restart: on-failure
volumes:
- ${PWD}/nginx:/etc/nginx/conf.d:ro
- ${PWD}/mybb:/var/www/html:ro
Expand All @@ -28,6 +29,7 @@ services:
networks:
- frontend
- backend
restart: on-failure
volumes:
- ${PWD}/mybb:/var/www/html

Expand All @@ -44,6 +46,7 @@ services:
tag: "{{.DaemonName}}(image={{.ImageName}};name={{.Name}};id={{.ID}})"
networks:
- backend
restart: on-failure
volumes:
- ${PWD}/mariadb:/var/lib/mysql

Expand All @@ -55,6 +58,7 @@ services:
tag: "{{.DaemonName}}(image={{.ImageName}};name={{.Name}};id={{.ID}})"
networks:
- backend
restart: on-failure

networks:
frontend:
Expand Down
4 changes: 4 additions & 0 deletions docker-compose.yml.pgsql.example
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ services:
- frontend
ports:
- '8080:80'
restart: on-failure
volumes:
- ${PWD}/nginx:/etc/nginx/conf.d:ro
- ${PWD}/mybb:/var/www/html:ro
Expand All @@ -28,6 +29,7 @@ services:
networks:
- frontend
- backend
restart: on-failure
volumes:
- ${PWD}/mybb:/var/www/html

Expand All @@ -48,6 +50,7 @@ services:
tag: "{{.DaemonName}}(image={{.ImageName}};name={{.Name}};id={{.ID}})"
networks:
- backend
restart: on-failure
volumes:
- ${PWD}/postgres/data:/var/lib/postgresql/data

Expand All @@ -59,6 +62,7 @@ services:
tag: "{{.DaemonName}}(image={{.ImageName}};name={{.Name}};id={{.ID}})"
networks:
- backend
restart: on-failure

networks:
frontend:
Expand Down

0 comments on commit 8cc2901

Please sign in to comment.