Remove Traefik — use simple port binding for NPM
Stack uses Tailscale + Nginx Proxy Manager, not Traefik. Client exposes PORT (default 3080) for NPM to proxy to. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -12,5 +12,8 @@ POSTGRES_PASSWORD=change-this-to-a-strong-password
|
||||
# Generate with: openssl rand -hex 64
|
||||
JWT_SECRET=change-this-to-a-long-random-string
|
||||
|
||||
# Fully-qualified domain — must match your Traefik routing rule
|
||||
DOMAIN=tickets.thewrightserver.net
|
||||
# Origin NPM proxies to this app (used for CORS)
|
||||
CLIENT_URL=http://tickets.thewrightserver.net
|
||||
|
||||
# Host port NPM proxies to — change if 3080 is taken
|
||||
PORT=3080
|
||||
|
||||
@@ -19,7 +19,7 @@ Internal ticketing system with CTI-based routing, severity levels, and n8n/autom
|
||||
### Prerequisites
|
||||
|
||||
- Docker + Docker Compose
|
||||
- Traefik running with a `proxy` Docker network
|
||||
- Nginx Proxy Manager pointed at the host port (default `3080`)
|
||||
- Access to your Gitea container registry
|
||||
|
||||
### 1. Copy files to your server
|
||||
@@ -42,9 +42,12 @@ REGISTRY=gitea.thewrightserver.net
|
||||
TAG=latest
|
||||
POSTGRES_PASSWORD=<strong password>
|
||||
JWT_SECRET=<output of: openssl rand -hex 64>
|
||||
DOMAIN=tickets.thewrightserver.net
|
||||
CLIENT_URL=http://tickets.thewrightserver.net
|
||||
PORT=3080
|
||||
```
|
||||
|
||||
Point NPM at `http://<host-ip>:3080` for the proxy host.
|
||||
|
||||
### 3. Create the initial database migration
|
||||
|
||||
Run this **once** on your local dev machine before first deploy, then commit the result:
|
||||
|
||||
@@ -28,7 +28,7 @@ services:
|
||||
environment:
|
||||
DATABASE_URL: postgresql://postgres:${POSTGRES_PASSWORD}@postgres:5432/ticketing
|
||||
JWT_SECRET: ${JWT_SECRET}
|
||||
CLIENT_URL: https://${DOMAIN}
|
||||
CLIENT_URL: ${CLIENT_URL}
|
||||
PORT: 3000
|
||||
depends_on:
|
||||
postgres:
|
||||
@@ -39,23 +39,16 @@ services:
|
||||
client:
|
||||
image: ${REGISTRY}/josh/ticketing-client:${TAG:-latest}
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "${PORT:-3080}:80"
|
||||
depends_on:
|
||||
- server
|
||||
networks:
|
||||
- internal
|
||||
- proxy
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.tickets.rule=Host(`${DOMAIN}`)"
|
||||
- "traefik.http.routers.tickets.entrypoints=websecure"
|
||||
- "traefik.http.routers.tickets.tls.certresolver=letsencrypt"
|
||||
- "traefik.http.services.tickets.loadbalancer.server.port=80"
|
||||
|
||||
networks:
|
||||
internal:
|
||||
driver: bridge
|
||||
proxy:
|
||||
external: true # Traefik's proxy network
|
||||
|
||||
volumes:
|
||||
postgres_data:
|
||||
|
||||
Reference in New Issue
Block a user