-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
38 lines (29 loc) · 1.3 KB
/
.env.example
File metadata and controls
38 lines (29 loc) · 1.3 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
# MongoDB Connection (Atlas)
# Option 1: Username/Password Authentication
# MONGODB_URI=mongodb+srv://<username>:<password>@<cluster>.mongodb.net/<database>?retryWrites=true&w=majority
# Option 2: X.509 Certificate Authentication (Recommended for production)
MONGODB_URI=mongodb+srv://<cluster>.mongodb.net/?authSource=%24external&authMechanism=MONGODB-X509&retryWrites=true&w=majority&appName=<AppName>
MONGODB_DB_NAME=your_database_name
# X.509 Certificate Path (required if using X.509 authentication)
MONGODB_CERT_PATH=/path/to/your/certificate.pem
# Optional: Separate read-only connection for dashboard queries
MONGODB_READONLY_URI=mongodb+srv://<readonly_user>:<password>@<cluster>.mongodb.net/<database>?retryWrites=true&w=majority
# Cache Settings
CACHE_TTL_SECONDS=300
# API Rate Limiting
API_RATE_LIMIT_MAX_REQUESTS=100
API_RATE_LIMIT_WINDOW_MS=60000
# Date Range Limits (days) - Set to 100 years (effectively unlimited)
# With SQLite caching, large date ranges are performant
MAX_DATE_RANGE_DAYS=36500
# Batch Aggregation Settings
BATCH_INCREMENTAL_DAYS=7
# Collection Names - MongoDB
COLLECTION_ORDERS=bills
COLLECTION_PAYMENTS=bills
COLLECTION_MENUS=stores
# SQLite Cache Settings
SQLITE_DB_PATH=./data/cache.db
CACHE_REFRESH_TOKEN=your-secret-token-here
CACHE_AUTO_REFRESH=true
CACHE_INCREMENTAL_DAYS=7