Skip to content

Commit

Permalink
Docker compose changes
Browse files Browse the repository at this point in the history
  • Loading branch information
DerekRoberts committed Oct 9, 2024
1 parent 4f8e4d1 commit 8f56155
Showing 1 changed file with 22 additions and 4 deletions.
26 changes: 22 additions & 4 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,9 @@ services:
#############################################################################################
frontend:
working_dir: /app
build:
context: ./frontend
dockerfile: Dockerfile
# build:
# context: ./frontend
# dockerfile: Dockerfile
hostname: frontend
environment:
DEBUG: "true"
Expand All @@ -117,7 +117,8 @@ services:
API_TARGET: "http://localhost:8000/"
BACKEND_URL: "http://localhost:8000"
LOG_LEVEL: "info"
command: caddy run --config /etc/caddy/Caddyfile
command: npm i && npm run server
image: node:14.21.3
ports:
- "3000:3000"
volumes:
Expand All @@ -127,6 +128,23 @@ services:
backend:
condition: service_started

caddy:
container_name: caddy
profiles: ["caddy"]
build: ./frontend
environment:
NODE_ENV: development
PORT: 3000
BACKEND_URL: http://backend:3000
LOG_LEVEL: info
ports: ["3005:3000"]
volumes: ["./frontend/Caddyfile:/etc/caddy/Caddyfile"]
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:3000"]
depends_on:
backend:
condition: service_healthy

#############################################################################################
### Backend ###
#############################################################################################
Expand Down

0 comments on commit 8f56155

Please sign in to comment.