Update docker-compose.yml
This commit is contained in:
@@ -23,29 +23,30 @@ services:
|
||||
- "traefik.enable=true"
|
||||
|
||||
nextjs-app:
|
||||
build:
|
||||
context: . # Path to your project
|
||||
dockerfile: Dockerfile
|
||||
container_name: nextjs-app-container
|
||||
expose:
|
||||
- "3000" # Expose port 3000 internally (not externally)
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.nextjs-app.rule=Host(`dash.embermarket.app`)"
|
||||
- "traefik.http.services.nextjs-app.loadbalancer.server.port=3000"
|
||||
build:
|
||||
context: . # Path to your project
|
||||
dockerfile: Dockerfile
|
||||
container_name: nextjs-app-container
|
||||
expose:
|
||||
- "3000" # Expose port 3000 internally (not externally)
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.nextjs-app.rule=Host(`dash.embermarket.app`)"
|
||||
- "traefik.http.services.nextjs-app.loadbalancer.server.port=3000"
|
||||
|
||||
# IP Whitelist middleware for the Next.js app
|
||||
- "traefik.http.routers.nextjs-app.middlewares=ip-whitelist" # Apply the IP whitelist middleware
|
||||
# IP Whitelist middleware for the Next.js app
|
||||
- "traefik.http.routers.nextjs-app.middlewares=ip-whitelist@file" # Use @file to reference middleware from a file provider
|
||||
|
||||
# Define the IP whitelist middleware for the Next.js app
|
||||
- "traefik.http.middlewares.ip-whitelist.ipWhiteList.sourcerange=212.113.116.6,194.26.229.41,138.124.13.13" # Allowed IPs
|
||||
# Define the IP whitelist middleware for the Next.js app
|
||||
- "traefik.http.middlewares.ip-whitelist@file.ipWhiteList.sourcerange=212.113.116.6,194.26.229.41,138.124.13.13" # Allowed IPs
|
||||
|
||||
environment:
|
||||
- NODE_ENV=production
|
||||
- NEXT_PUBLIC_API_URL=https://internal-api.inboxi.ng/api
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- web
|
||||
|
||||
environment:
|
||||
- NODE_ENV=production
|
||||
- NEXT_PUBLIC_API_URL=https://internal-api.inboxi.ng/api
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- web
|
||||
|
||||
networks:
|
||||
web:
|
||||
|
||||
Reference in New Issue
Block a user