Fix Docker Compose to use cached images instead of rebuilding
- Changed pull_policy from 'build' to 'missing' for frontend and backend - Added explicit image names (mad-lawsuit-frontend:latest, mad-lawsuit-backend:latest) - This prevents unnecessary rebuilds on server when restarting containers - Images will only rebuild when explicitly requested or when missing
This commit is contained in:
parent
ba654296e9
commit
1d37b1fdae
1 changed files with 4 additions and 2 deletions
|
|
@ -1,9 +1,10 @@
|
|||
services:
|
||||
frontend:
|
||||
image: mad-lawsuit-frontend:latest
|
||||
build:
|
||||
context: ./frontend
|
||||
dockerfile: Dockerfile
|
||||
pull_policy: build
|
||||
pull_policy: missing
|
||||
ports:
|
||||
- "806:806"
|
||||
environment:
|
||||
|
|
@ -17,10 +18,11 @@ services:
|
|||
- caddy_network
|
||||
|
||||
backend:
|
||||
image: mad-lawsuit-backend:latest
|
||||
build:
|
||||
context: ./backend
|
||||
dockerfile: Dockerfile
|
||||
pull_policy: build
|
||||
pull_policy: missing
|
||||
ports:
|
||||
- "901:3001"
|
||||
environment:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue