-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathenv.example
More file actions
175 lines (139 loc) · 6.66 KB
/
env.example
File metadata and controls
175 lines (139 loc) · 6.66 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
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
# Cloud API Configuration via Environment Variables
# Copy this file to .env and fill in your actual values
# =============================================================================
# Server Configuration
# =============================================================================
SERVER_HOST=0.0.0.0
SERVER_PORT=3000
# =============================================================================
# Model Discovery Configuration
# =============================================================================
# URL of the model discovery server
MODEL_DISCOVERY_SERVER_URL=http://localhost:8080/models
# API key for authenticating with discovered model providers
MODEL_DISCOVERY_API_KEY=YOUR_API_KEY_HERE
# How often to refresh model list (in seconds)
MODEL_DISCOVERY_REFRESH_INTERVAL=300
# Discovery request timeout (in seconds)
MODEL_DISCOVERY_TIMEOUT=5
# Model inference timeout (in seconds) - set to 30 minutes for large models
MODEL_INFERENCE_TIMEOUT=18000
# =============================================================================
# Logging Configuration
# =============================================================================
# Global log level: trace, debug, info, warn, error
LOG_LEVEL=info
# Log format: json, compact, pretty
# Use 'json' for containerized environments with Datadog agent
# Use 'compact' for local development
# Use 'pretty' for debugging
LOG_FORMAT=json
# Module-specific log levels (optional)
LOG_MODULE_API=info
LOG_MODULE_SERVICES=info
# =============================================================================
# DStack Client Configuration
# =============================================================================
DSTACK_CLIENT_URL=http://localhost:8000
# =============================================================================
# Authentication Configuration
# =============================================================================
# Set to true to use mock authentication (development only)
AUTH_MOCK=false
# Set for JWT access token encoding
AUTH_ENCODING_KEY=YOUR_AUTH_ENCODING_KEY
# GitHub OAuth Configuration
# To set up:
# 1. Go to https://github.com/settings/developers
# 2. Create a new OAuth App
# 3. Set Authorization callback URL to: http://your-domain:3000/v1/auth/callback
# 4. Copy Client ID and Client Secret here
GITHUB_CLIENT_ID=YOUR_GITHUB_CLIENT_ID
GITHUB_CLIENT_SECRET=YOUR_GITHUB_CLIENT_SECRET
GITHUB_REDIRECT_URL=http://localhost:3000/v1/auth/callback
# Google OAuth Configuration
# To set up:
# 1. Go to https://console.cloud.google.com/apis/credentials
# 2. Create OAuth 2.0 Client ID
# 3. Add authorized redirect URI: http://your-domain:3000/v1/auth/callback
# 4. Copy Client ID and Client Secret here
GOOGLE_CLIENT_ID=YOUR_GOOGLE_CLIENT_ID.apps.googleusercontent.com
GOOGLE_CLIENT_SECRET=YOUR_GOOGLE_CLIENT_SECRET
GOOGLE_REDIRECT_URL=http://localhost:3000/v1/auth/callback
# NEAR OAuth Configuration
NEAR_EXPECTED_RECIPIENT=cloud.near.ai
# Admin Configuration
# Comma-separated list of email domains that are granted admin access
# Example: near.ai,admin.org
AUTH_ADMIN_DOMAINS=near.ai
# =============================================================================
# Database Configuration
# =============================================================================
# Primary app ID for Patroni/PostgreSQL cluster discovery
# Use "postgres-test" for simple postgres connection without Patroni
POSTGRES_PRIMARY_APP_ID=postgres-test
# Gateway subdomain for Patroni discovery (only used in production with Patroni)
GATEWAY_SUBDOMAIN=localhost
DATABASE_HOST=localhost
DATABASE_PORT=5432
DATABASE_NAME=platform_api
DATABASE_USERNAME=postgres
DATABASE_PASSWORD=postgres
DATABASE_MAX_CONNECTIONS=5
# TLS/SSL for remote database connections (e.g., DigitalOcean, AWS RDS)
DATABASE_TLS_ENABLED=false
# Path to custom CA certificate (optional, for databases with custom certs)
# DATABASE_TLS_CA_CERT_PATH=path/to/ca-certificate.crt
# Database migration SQL files directory (optional, for custom migration files path)
# DATABASE_MIGRATIONS_PATH=path/to/migrations/sql/directory
# =============================================================================
# AWS S3 Configuration (for file uploads)
# =============================================================================
# S3 bucket name for file storage
AWS_S3_BUCKET=your-bucket-name
# AWS S3 region
AWS_S3_REGION=us-east-1
# AWS credentials (alternatively, use AWS CLI/environment credentials)
# AWS_ACCESS_KEY_ID=your-access-key-id
# AWS_SECRET_ACCESS_KEY=your-secret-access-key
# S3 Encryption Key Configuration
# Encryption key for files stored in S3 (must be 256-bit / 32 bytes, hex-encoded)
# Generate a key: openssl rand -hex 32
# Use either S3_ENCRYPTION_KEY or S3_ENCRYPTION_KEY_FILE (mounted secret in production)
S3_ENCRYPTION_KEY=your-hex-encoded-256-bit-encryption-key
# S3_ENCRYPTION_KEY_FILE=/path/to/encryption-key-file
# =============================================================================
# Optional: Configuration Loading Mode
# =============================================================================
# Uncomment to explicitly use environment variables instead of config.yaml
# USE_ENV_CONFIG=true
# Or specify a custom config file path
# CONFIG_FILE=config/custom.yaml
# =============================================================================
# Integration Test Configuration (Optional)
# =============================================================================
# These variables are used by integration tests. If not set, tests will use
# default values suitable for local testing.
# vLLM Integration Tests
# VLLM_BASE_URL=http://localhost:8002
# VLLM_API_KEY=your_vllm_api_key_here
# VLLM_TEST_TIMEOUT_SECS=30
# =============================================================================
# Datadog Configuration (for Monitoring & Observability)
# =============================================================================
# Datadog API Key - Get this from https://app.datadoghq.com/account/settings#api
# REQUIRED for Datadog agent to send metrics/logs to Datadog
DD_API_KEY=your-datadog-api-key-here
# Datadog Site - Select your Datadog site region
# Options: datadoghq.com (US1), us3.datadoghq.com (US3), us5.datadoghq.com (US5),
# datadoghq.eu (EU1), ddog-gov.com (US1-FED)
DD_SITE=us3.datadoghq.com
# Environment tag for metrics (local, dev, staging, prod)
ENVIRONMENT=local
# =============================================================================
# OpenTelemetry Configuration
# =============================================================================
# OTLP endpoint for sending metrics (points to Datadog agent in docker-compose)
# TELEMETRY_OTLP_ENDPOINT=http://datadog-agent:4317
# TELEMETRY_OTLP_PROTOCOL=grpc
BRAVE_SEARCH_PRO_API_KEY=MY_KEY