"""
feat: Update frontend and backend configurations for development environment - Downgrade PyP100 version in requirements.txt for compatibility. - Add new frontend routes for index, login, dashboard, printers, jobs, and profile pages. - Modify docker-compose files for development setup, including environment variables and service names. - Update Caddyfile for local development with Raspberry Pi backend. - Adjust health check route to use updated backend URL. - Enhance setup-backend-url.sh for development environment configuration. """
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
# 🎨 MYP Frontend - Standalone Server Konfiguration
|
||||
# Frontend-Service als vollständig unabhängiger Server
|
||||
# 🎨 MYP Frontend - Entwicklungsumgebung Konfiguration
|
||||
# Frontend-Service für die Entwicklung mit Raspberry Pi Backend
|
||||
|
||||
version: '3.8'
|
||||
|
||||
@@ -8,33 +8,38 @@ services:
|
||||
frontend:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
dockerfile: Dockerfile.dev
|
||||
args:
|
||||
- BUILDKIT_INLINE_CACHE=1
|
||||
- NODE_ENV=${NODE_ENV:-production}
|
||||
image: myp/frontend:latest
|
||||
container_name: myp-frontend-standalone
|
||||
- NODE_ENV=development
|
||||
image: myp/frontend:dev
|
||||
container_name: myp-frontend-dev
|
||||
restart: unless-stopped
|
||||
|
||||
environment:
|
||||
- NODE_ENV=${NODE_ENV:-production}
|
||||
- NODE_ENV=development
|
||||
- NEXT_TELEMETRY_DISABLED=1
|
||||
|
||||
# Backend API Konfiguration
|
||||
- NEXT_PUBLIC_API_URL=${BACKEND_API_URL:-http://localhost:5000/api}
|
||||
- NEXT_PUBLIC_BACKEND_HOST=${BACKEND_HOST:-localhost:5000}
|
||||
# Backend API Konfiguration (Raspberry Pi)
|
||||
- NEXT_PUBLIC_API_URL=http://192.168.0.105:5000
|
||||
- NEXT_PUBLIC_BACKEND_HOST=192.168.0.105:5000
|
||||
|
||||
# Frontend Server
|
||||
- PORT=3000
|
||||
- HOSTNAME=0.0.0.0
|
||||
|
||||
# Auth Konfiguration
|
||||
- NEXTAUTH_URL=${FRONTEND_URL:-http://localhost:3000}
|
||||
- NEXTAUTH_SECRET=${NEXTAUTH_SECRET:-frontend-auth-secret}
|
||||
# Auth Konfiguration (Entwicklung)
|
||||
- NEXTAUTH_URL=http://localhost:3000
|
||||
- NEXTAUTH_SECRET=dev-frontend-auth-secret
|
||||
|
||||
# Debug-Einstellungen
|
||||
- DEBUG=true
|
||||
- NEXT_DEBUG=true
|
||||
|
||||
volumes:
|
||||
- frontend_data:/app/.next
|
||||
- frontend_cache:/app/.next/cache
|
||||
- .:/app
|
||||
- /app/node_modules
|
||||
- /app/.next
|
||||
- ./public:/app/public:ro
|
||||
|
||||
ports:
|
||||
@@ -43,6 +48,9 @@ services:
|
||||
networks:
|
||||
- frontend-network
|
||||
|
||||
extra_hosts:
|
||||
- "raspberrypi:192.168.0.105"
|
||||
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:3000/health"]
|
||||
interval: 30s
|
||||
@@ -52,8 +60,8 @@ services:
|
||||
|
||||
labels:
|
||||
- "service.type=frontend"
|
||||
- "service.name=myp-frontend"
|
||||
- "service.environment=${NODE_ENV:-production}"
|
||||
- "service.name=myp-frontend-dev"
|
||||
- "service.environment=development"
|
||||
|
||||
# === FRONTEND CACHE (Optional: Redis für Session Management) ===
|
||||
frontend-cache:
|
||||
|
Reference in New Issue
Block a user