From d7ca646eba6b430804636094cf4eff834b22af0d Mon Sep 17 00:00:00 2001 From: NotII <46204250+NotII@users.noreply.github.com> Date: Sun, 9 Mar 2025 00:07:16 +0000 Subject: [PATCH] Update docker-compose.yml --- docker-compose.yml | 45 +++++++++++++++++++++++++++++++-------------- 1 file changed, 31 insertions(+), 14 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 96c18ae..6d6af26 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,33 +1,50 @@ -version: '3.8' +version: '3' services: + # AEZA (WAF) Service + aeza: + image: aeza/waf:latest + container_name: aeza-waf + ports: + - "80:80" # Expose AEZA on port 80 + - "443:443" # Expose AEZA on port 443 + labels: + - "traefik.enable=false" # Disable Traefik routing directly to AEZA + environment: + - WAF_ENABLE=true + - WAF_API_URL=https://internal-api.inboxi.ng/api # Update with your WAF config + restart: unless-stopped + + # Traefik reverse proxy traefik: - image: traefik:v2.7 + image: traefik:v2.9 container_name: traefik command: - - "--api.insecure=true" + - "--api.insecure=true" # Enable Traefik dashboard - "--entrypoints.web.address=:80" - "--entrypoints.websecure.address=:443" - - "--providers.docker=true" + - "--providers.docker=true" # Enable Docker provider ports: - - "80:80" - - "443:443" - - "8080:8080" # Traefik dashboard + - "80:80" # Expose HTTP port + - "443:443" # Expose HTTPS port + - "8080:8080" # Traefik Dashboard port (optional) volumes: - - "/var/run/docker.sock:/var/run/docker.sock" + - "/var/run/docker.sock:/var/run/docker.sock" # Allow Traefik to monitor Docker + restart: unless-stopped + # Next.js application nextjs-app: build: - context: . # Path to your project + context: . dockerfile: Dockerfile container_name: nextjs-app-container expose: - - "3000" # Expose port 3000 internally - labels: - - "traefik.enable=true" - - "traefik.http.routers.dashboard.rule=Host(`dash.embermarket.app`)" - - "traefik.http.services.dashboard.loadbalancer.server.port=3000" + - "3000" # Expose Next.js app inside the Docker network environment: - NODE_ENV=production - NEXT_PUBLIC_API_URL=https://internal-api.inboxi.ng/api + labels: + - "traefik.enable=true" + - "traefik.http.routers.dashboard.rule=Host(`dash.embermarket.app`)" # Use AEZA as reverse proxy + - "traefik.http.services.dashboard.loadbalancer.server.port=3000" restart: unless-stopped