백엔드 도커 설정

This commit is contained in:
kjs
2025-08-22 15:45:05 +09:00
parent 38216b3ddc
commit caacd0e0a4
8 changed files with 113 additions and 57 deletions

View File

@@ -1,29 +1,31 @@
version: '3.8'
version: "3.8"
services:
# Spring Boot 백엔드
# Node.js 백엔드
backend:
build:
context: ./backend
context: ./backend-node
dockerfile: Dockerfile
container_name: pms-backend-linux
ports:
- "8080:8080"
environment:
- SPRING_PROFILES_ACTIVE=dev
- SPRING_DATASOURCE_URL=jdbc:postgresql://39.117.244.52:11132/plm?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Seoul
- SPRING_DATASOURCE_USERNAME=postgres
- SPRING_DATASOURCE_PASSWORD=ph0909!!
- LANG=ko_KR.UTF-8
- LANGUAGE=ko_KR:ko
- LC_ALL=ko_KR.UTF-8
- TZ=Asia/Seoul
- JAVA_OPTS=-Xms512m -Xmx1024m -Dfile.encoding=UTF-8 -Duser.timezone=Asia/Seoul -Djava.awt.headless=true
- NODE_ENV=development
- PORT=8080
- DATABASE_URL=postgresql://postgres:ph0909!!@39.117.244.52:11132/plm
- JWT_SECRET=ilshin-plm-super-secret-jwt-key-2024
- JWT_EXPIRES_IN=24h
- CORS_ORIGIN=http://localhost:9771
- CORS_CREDENTIALS=true
- LOG_LEVEL=debug
volumes:
- ./backend-node:/app
- /app/node_modules
networks:
- pms-network
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8080/api/actuator/health"]
test: ["CMD", "curl", "-f", "http://localhost:8080/health"]
interval: 30s
timeout: 10s
retries: 3
@@ -31,4 +33,4 @@ services:
networks:
pms-network:
driver: bridge
driver: bridge