feat(deploy): add staging environment with dedicated docker compose
CI — Test & Build / 🧪 Run Tests & Generate Reports (push) Waiting to run
CI — Test & Build / 🏗️ Build Docker Image (push) Blocked by required conditions

- Add docker-compose.staging.yml (app on 127.0.0.1:8081, separate MongoDB
  on 127.0.0.1:27019, dedicated volume/network)
- deploy.sh: select compose file and port per environment
  (staging 8081, production 8080)
- Dockerfile: accept NEXT_PUBLIC_SITE_URL as build arg (inlined at build
  time for NEXT_PUBLIC_ vars); pass it in both compose files
- Add .env.staging.example and .env.production.example
This commit is contained in:
Do Siki
2026-08-17 13:07:51 +02:00
parent c37787251b
commit 35bf43798d
6 changed files with 118 additions and 7 deletions
+2 -2
View File
@@ -1,5 +1,3 @@
version: '3.8'
services:
# Next.js Application (Production Mode)
app:
@@ -7,6 +5,8 @@ services:
context: ./proto
dockerfile: Dockerfile
target: runner # Use runner stage for production (smaller size, no dev dependencies)
args:
- NEXT_PUBLIC_SITE_URL=${NEXT_PUBLIC_SITE_URL:-https://mozdit.hu}
container_name: mozdit-app-prod
ports:
- "8080:3000" # Host port 8080 elkerüli a lokális npm dev (3000) összeakadást