🚀 Deployment-Konfiguration hinzugefügt
- docker-compose.yml (DB + Backend + Frontend) - Nginx Reverse Proxy Config - Deployment Script Ports: - PostgreSQL: 5434 - Backend: 8004 - Frontend: 3006
This commit is contained in:
65
deploy/docker-compose.yml
Normal file
65
deploy/docker-compose.yml
Normal file
@@ -0,0 +1,65 @@
|
||||
version: '3.8'
|
||||
|
||||
services:
|
||||
secu-db:
|
||||
image: postgres:16-alpine
|
||||
container_name: secu-db
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
POSTGRES_USER: secu
|
||||
POSTGRES_PASSWORD: SeCu2026!SecureDB
|
||||
POSTGRES_DB: secu
|
||||
volumes:
|
||||
- secu-db-data:/var/lib/postgresql/data
|
||||
- ../db/migrations:/docker-entrypoint-initdb.d:ro
|
||||
ports:
|
||||
- "5434:5432"
|
||||
networks:
|
||||
- secu-network
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U secu -d secu"]
|
||||
interval: 10s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
secu-backend:
|
||||
image: denoland/deno:alpine
|
||||
container_name: secu-backend
|
||||
restart: unless-stopped
|
||||
working_dir: /app
|
||||
command: deno run --allow-net --allow-env --allow-read src/main.ts
|
||||
environment:
|
||||
DATABASE_URL: postgres://secu:SeCu2026!SecureDB@secu-db:5432/secu
|
||||
JWT_SECRET: ${JWT_SECRET:-SeCu-Production-Secret-Change-Me-2026}
|
||||
PORT: 8004
|
||||
volumes:
|
||||
- ../../secu-backend:/app:ro
|
||||
ports:
|
||||
- "8004:8004"
|
||||
networks:
|
||||
- secu-network
|
||||
depends_on:
|
||||
secu-db:
|
||||
condition: service_healthy
|
||||
|
||||
secu-frontend:
|
||||
image: node:20-alpine
|
||||
container_name: secu-frontend
|
||||
restart: unless-stopped
|
||||
working_dir: /app
|
||||
command: sh -c "npm install && npm run build && npx serve -s dist -l 3006"
|
||||
environment:
|
||||
VITE_API_URL: https://api.secu.kronos-soulution.de/api
|
||||
volumes:
|
||||
- ../../secu-frontend:/app
|
||||
ports:
|
||||
- "3006:3006"
|
||||
networks:
|
||||
- secu-network
|
||||
|
||||
volumes:
|
||||
secu-db-data:
|
||||
|
||||
networks:
|
||||
secu-network:
|
||||
driver: bridge
|
||||
Reference in New Issue
Block a user