-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path.env.example
More file actions
84 lines (72 loc) · 4.07 KB
/
.env.example
File metadata and controls
84 lines (72 loc) · 4.07 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
# -----------------------------------------------------------------------------
# MONGO DB CONFIGURATION
# -----------------------------------------------------------------------------
# Required for the 'auth' and 'backend' services.
# Use a local MongoDB instance for development or a cloud provider like MongoDB Atlas for production.
MONGODB_URI=mongodb://localhost:27017/amberops
# -----------------------------------------------------------------------------
# AUTHENTICATION & SESSION MANAGEMENT
# -----------------------------------------------------------------------------
# A strong, random secret key for signing JSON Web Tokens (JWTs).
# Required for the 'auth' service.
# Use a secure, randomly generated string in production (e.g., `openssl rand -hex 32`).
JWT_SECRET=your-super-secret-jwt-key-that-is-long-and-random
# The secret key for Express session middleware, used for Passport OAuth flows.
# Required for the 'auth' service.
SESSION_SECRET=your-super-secret-session-key
# The domain for setting HttpOnly session cookies.
# For local development, this should be 'localhost'.
# For production, this should be your root domain (e.g., '.amberops.com') to allow sharing cookies across subdomains.
COOKIE_DOMAIN=localhost
# -----------------------------------------------------------------------------
# GOOGLE & GITHUB OAUTH (Optional)
# -----------------------------------------------------------------------------
# Required for the 'auth' service to enable Google/GitHub social logins.
# If you don't provide these, the respective login buttons will be hidden.
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
GITHUB_CLIENT_ID=
GITHUB_CLIENT_SECRET=
# -----------------------------------------------------------------------------
# CORS & URLS
# -----------------------------------------------------------------------------
# A comma-separated list of allowed origins for the backend services.
# This is crucial for security in production.
CORS_ORIGINS=http://localhost:3000,http://localhost:3001,http://localhost:3003
# URLs for all frontend applications. These are used by the backend services
# to construct redirect URLs after authentication.
# In a production environment, these should be your public-facing URLs.
NEXT_PUBLIC_HOME_URL=http://localhost:3001
NEXT_PUBLIC_WEB_URL=http://localhost:3000
NEXT_PUBLIC_ADMIN_URL=http://localhost:3003
# -----------------------------------------------------------------------------
# API ENDPOINTS
# -----------------------------------------------------------------------------
# The base URL for the standalone authentication service API.
# Used by the 'home' application to make login/registration requests.
NEXT_PUBLIC_AUTH_API_URL=http://localhost:3002/api
# The base URL for the main application data API.
# This is used by all frontend applications to fetch data from the 'backend' service.
# NOTE: In a production environment where apps are on different subdomains, you would
# provide the full URL (e.g., https://api.amberops.com/api/v1). For local development,
# relative paths with rewrites in next.config.js are used.
NEXT_PUBLIC_API_BASE_URL=/api/v1
# -----------------------------------------------------------------------------
# GOOGLE GEMINI AI (Optional)
# -----------------------------------------------------------------------------
# Your API key for Google Gemini.
# Required for all AI-powered features in the 'web' application, like health summaries
# and troubleshooting steps. If not provided, these features will be disabled.
GEMINI_API_KEY=
# -----------------------------------------------------------------------------
# SERVICE PORTS (For local development)
# -----------------------------------------------------------------------------
# Defines the ports that the local development servers will run on.
AUTH_PORT=3002
BACKEND_PORT=3004
# -----------------------------------------------------------------------------
# LOGGING
# -----------------------------------------------------------------------------
# Set to 'true' to enable detailed console logging in all services.
# Recommended to be 'false' in production to reduce noise.
NEXT_PUBLIC_LOGGING_ENABLED=true