-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
143 lines (110 loc) · 5.38 KB
/
Copy path.env.example
File metadata and controls
143 lines (110 loc) · 5.38 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
# =============================================================================
# OnHyper.io Environment Configuration
# =============================================================================
# Copy this file to .env and fill in the values for your environment.
# In production, all secrets MUST be set to secure random values.
# =============================================================================
# -----------------------------------------------------------------------------
# SERVER CONFIGURATION
# -----------------------------------------------------------------------------
# Port to listen on (default: 3000)
PORT=3000
# Host to bind to (default: 0.0.0.0 for all interfaces)
HOST=0.0.0.0
# Public URL of your OnHyper instance
# Used for generating app URLs and email links
BASE_URL=http://localhost:3000
# Path to serve static frontend files from
STATIC_PATH=./public
# -----------------------------------------------------------------------------
# DATABASE CONFIGURATION
# -----------------------------------------------------------------------------
# Data directory for SQLite and LMDB databases
# In production, this should point to a persistent volume
# Railway sets RAILWAY_VOLUME_MOUNT_PATH automatically when volume is attached
DATA_DIR=./data
# SQLite database path (default: $DATA_DIR/onhyper.db)
SQLITE_PATH=./data/onhyper.db
# LMDB database path (default: $DATA_DIR/onhyper.lmdb)
LMDB_PATH=./data/onhyper.lmdb
# -----------------------------------------------------------------------------
# SECURITY SECRETS (REQUIRED IN PRODUCTION)
# -----------------------------------------------------------------------------
# JWT secret for signing authentication tokens
# Generate with: openssl rand -hex 32
# REQUIRED in production - server will not start with default value
ONHYPER_JWT_SECRET=dev-jwt-secret-change-in-production
# Master encryption key for user secrets
# Used to derive encryption keys for API keys stored in the database
# Generate with: openssl rand -hex 32
# REQUIRED in production - server will not start with default value
ONHYPER_MASTER_KEY=dev-master-key-change-in-production
# -----------------------------------------------------------------------------
# AUTHENTICATION SETTINGS
# -----------------------------------------------------------------------------
# Bcrypt rounds for password hashing (default: 10)
# Higher is more secure but slower
AUTH_BCRYPT_ROUNDS=10
# JWT token expiration (default: 7d)
# Examples: 1h, 24h, 7d, 30d
JWT_EXPIRES_IN=7d
# Minimum password length (default: 8)
AUTH_MIN_PASSWORD_LENGTH=8
# -----------------------------------------------------------------------------
# RATE LIMITING
# -----------------------------------------------------------------------------
# Time window for rate limiting in milliseconds (default: 60000 = 1 minute)
RATE_LIMIT_WINDOW_MS=60000
# Max requests per window for general endpoints (default: 100)
RATE_LIMIT_MAX_REQUESTS=100
# -----------------------------------------------------------------------------
# PROXY SETTINGS
# -----------------------------------------------------------------------------
# Timeout for proxy requests in milliseconds (default: 30000 = 30 seconds)
PROXY_TIMEOUT_MS=30000
# Maximum request body size in bytes (default: 5242880 = 5MB)
PROXY_MAX_REQUEST_SIZE=5242880
# Maximum response body size in bytes (default: 5242880 = 5MB)
PROXY_MAX_RESPONSE_SIZE=5242880
# -----------------------------------------------------------------------------
# SCOUTOS INTEGRATION (SUPPORT CHAT)
# -----------------------------------------------------------------------------
# API key for ScoutOS (used for support chat agent)
# Get from https://scoutos.com
SCOUTOS_API_KEY=
# Agent ID for the support chat agent
SCOUTOS_SUPPORT_AGENT_ID=cmlo9s6t320kv5ts6xqz1ke84
# -----------------------------------------------------------------------------
# POSTHOG ANALYTICS
# -----------------------------------------------------------------------------
# PostHog API key for server-side tracking
# Get from https://app.posthog.com/project/settings
POSTHOG_KEY=phc_placeholder_replace_with_real_key
# PostHog API host (default: https://app.posthog.com)
POSTHOG_HOST=https://app.posthog.com
# -----------------------------------------------------------------------------
# EMAIL SERVICE (RESEND)
# -----------------------------------------------------------------------------
# Resend API key for sending emails
# Get from https://resend.com
RESEND_API_KEY=re_placeholder_replace_with_real_key
# Email address to send from
# Must be verified in Resend dashboard
RESEND_FROM_EMAIL=hello@onhyper.io
# =============================================================================
# PRODUCTION CHECKLIST
# =============================================================================
# Before deploying to production, ensure:
#
# [ ] ONHYPER_JWT_SECRET is set to a secure random 64-character hex string
# [ ] ONHYPER_MASTER_KEY is set to a secure random 64-character hex string
# [ ] DATA_DIR points to a persistent volume
# [ ] BASE_URL is set to your public domain (e.g., https://onhyper.io)
# [ ] POSTHOG_KEY is set for analytics
# [ ] RESEND_API_KEY and RESEND_FROM_EMAIL are configured for emails
# [ ] SCOUTOS_API_KEY is set if using support chat
#
# Generate secrets:
# openssl rand -hex 32 # For JWT_SECRET (use output)
# openssl rand -hex 32 # For MASTER_KEY (use output)
# =============================================================================