-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy path.env.docker.example
More file actions
148 lines (111 loc) · 3.61 KB
/
Copy path.env.docker.example
File metadata and controls
148 lines (111 loc) · 3.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
# ============================================================
# Open Short URL - Docker Environment Configuration
# ============================================================
# Copy this file to .env.docker and update the values.
#
# Usage:
# cp .env.docker.example .env.docker
# docker compose up -d
# ============================================================
# ============================
# INFRASTRUCTURE
# ============================
# PostgreSQL
POSTGRES_DB=open_short_url
POSTGRES_USER=postgres
POSTGRES_PASSWORD=changeme-strong-password
POSTGRES_PORT=5432
# Redis (leave empty for no password)
REDIS_PASSWORD=
REDIS_PORT=6379
# Port mapping
BACKEND_PORT=4101
FRONTEND_PORT=4100
# ============================
# BACKEND
# ============================
NODE_ENV=production
PORT=4101
HOST=0.0.0.0
# [REQUIRED] JWT secret - generate with: openssl rand -base64 32
JWT_SECRET=changeme-generate-a-strong-secret
JWT_EXPIRES_IN=7d
# [REQUIRED] Initial admin password
ADMIN_INITIAL_PASSWORD=changeme-strong-admin-password
# [REQUIRED] Short URL domain (the domain users see in shortened links)
# Example: https://example.com or https://s.example.com
SHORT_URL_DOMAIN=https://example.com
# [REQUIRED] Frontend URL (where the dashboard is hosted)
# Example: https://app.example.com or https://admin.example.com
FRONTEND_URL=https://app.example.com
# [REQUIRED] CORS allowed origins (usually same as FRONTEND_URL)
# Multiple origins: https://app.example.com,https://admin.example.com
CORS_ORIGIN=https://app.example.com
# Cookie domain (for cross-subdomain auth, e.g., .example.com)
COOKIE_DOMAIN=
# Trusted proxy (set to 'true' if behind nginx/cloudflare)
TRUSTED_PROXY=true
# ============================
# FRONTEND
# ============================
# Next.js needs HOSTNAME=0.0.0.0 to accept connections inside containers
HOSTNAME=0.0.0.0
# When building from source: passed as Docker build args
# When using pre-built GHCR images: replaced at container startup
NEXT_PUBLIC_API_URL=https://example.com
NEXT_PUBLIC_SHORT_URL_DOMAIN=https://example.com
NEXT_PUBLIC_LOCALE=en
NEXT_PUBLIC_BRAND_NAME=Open Short URL
NEXT_PUBLIC_BRAND_ICON_URL=
NEXT_PUBLIC_BRAND_DESCRIPTION=
NEXT_PUBLIC_DOCS_URL=https://supra126.github.io/open-short-url/
NEXT_PUBLIC_TURNSTILE_SITE_KEY=
# ============================
# OPTIONAL FEATURES
# ============================
# ============================
# MCP SERVER (AI integration)
# ============================
# Enable with: docker compose --profile mcp up -d
# [REQUIRED] API key for MCP → Backend communication
# Generate one in the backend dashboard under Settings → API Keys
MCP_API_KEY=
# MCP server port
MCP_PORT=3200
# ============================
# OBJECT STORAGE (S3/R2/MinIO)
# ============================
# Required for OG image upload feature.
# MinIO is included by default. To use Cloudflare R2 or AWS S3,
# change the endpoint and credentials below.
S3_REGION=auto
S3_ENDPOINT=http://minio:9000
S3_ACCESS_KEY_ID=minioadmin
S3_SECRET_ACCESS_KEY=minioadmin
S3_BUCKET=open-short-url
# CDN URL for serving public files (optional)
S3_PUBLIC_URL=
# Global prefix for multi-project isolation (optional)
S3_GLOBAL_PREFIX=
# MinIO ports
MINIO_PORT=9000
MINIO_CONSOLE_PORT=9001
# ============================
# OPTIONAL FEATURES
# ============================
# Swagger API documentation (disabled in production by default)
# SWAGGER_ENABLED=true
# Cloudflare Turnstile (anti-bot)
# TURNSTILE_SECRET_KEY=
# Rate Limiting
# THROTTLE_TTL=60
# THROTTLE_LIMIT=10
# Branding
# BRAND_NAME=Open Short URL
# BRAND_LOGO_URL=
# SMTP (email)
# SMTP_HOST=smtp.gmail.com
# SMTP_PORT=587
# SMTP_USER=
# SMTP_PASSWORD=
# SMTP_FROM=