backend docker refactor and frontend cleanup
This commit is contained in:
parent
96443b6afe
commit
63e33a45b4
14 changed files with 130 additions and 113 deletions
45
docker-compose.dev.yaml
Normal file
45
docker-compose.dev.yaml
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
services:
|
||||
db:
|
||||
container_name: recipes_db_dev
|
||||
image: docker.io/library/postgres:17
|
||||
restart: unless-stopped
|
||||
env_file:
|
||||
- .env
|
||||
environment:
|
||||
- POSTGRES_USER=${DB_USER}
|
||||
- POSTGRES_PASSWORD=${DB_PASSWORD}
|
||||
- POSTGRES_DB=${DB_NAME}
|
||||
ports:
|
||||
- "${DB_PORT}:5432"
|
||||
volumes:
|
||||
- ./db:/var/lib/postgresql/data
|
||||
backend:
|
||||
container_name: recipes_backend_dev
|
||||
image: recipes_backend
|
||||
restart: unless-stopped
|
||||
build:
|
||||
context: ./backend
|
||||
dockerfile: Dockerfile.dev
|
||||
ports:
|
||||
- "${BACKEND_PORT}:3000"
|
||||
volumes:
|
||||
- ./backend:/app
|
||||
- ./logs:/logs
|
||||
environment:
|
||||
- DB_USER=${DB_USER}
|
||||
- DB_PASSWORD=${DB_PASSWORD}
|
||||
- DB_NAME=${DB_NAME}
|
||||
- DATABASE_URL=${DATABASE_URL}
|
||||
frontend:
|
||||
container_name: recipes_frontend_dev
|
||||
image: recipes_frontend
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
- NODE_ENV=dev
|
||||
build:
|
||||
context: ./frontend
|
||||
dockerfile: Dockerfile.dev
|
||||
ports:
|
||||
- "${FRONTEND_PORT}:80"
|
||||
volumes:
|
||||
- ./frontend:/app
|
||||
Loading…
Add table
Add a link
Reference in a new issue