-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
63 lines (54 loc) · 2.45 KB
/
Copy path.env.example
File metadata and controls
63 lines (54 loc) · 2.45 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
# ----------------------------------------------------------------------------
# Secure Agent Orchestrator — environment template
# Copy to `.env` and fill in real values. Never commit the real `.env`.
# ----------------------------------------------------------------------------
# Application settings
APP_NAME="Secure Agent Orchestrator"
APP_DESCRIPTION="REST API for orchestrating commands to registered security agents"
APP_VERSION="0.2.0"
LICENSE_NAME="MIT"
CONTACT_NAME="Frangel Barrera"
CONTACT_EMAIL="security@frangelbarrera.dev"
# Environment: local | staging | production
# - local: docs and openapi are public, validators are relaxed but still reject
# known-insecure defaults (SECRET_KEY="secret-key", ADMIN_PASSWORD="!Ch4ng3Th1sP4ssW0rd!").
# - staging/production: docs/openapi are admin-only, CORS must be explicit,
# CRUD_ADMIN is off by default.
ENVIRONMENT="local"
# Cryptography — REQUIRED in every environment (including local).
# Generate one with:
# python -c "import secrets; print(secrets.token_urlsafe(32))"
SECRET_KEY="REPLACE_WITH_32_PLUS_CHAR_RANDOM_STRING"
ALGORITHM="HS256"
ACCESS_TOKEN_EXPIRE_MINUTES=30
REFRESH_TOKEN_EXPIRE_DAYS=7
# Database — SQLite only. File path is relative to the project root.
SQLITE_URI="./db.sqlite"
SQLITE_SYNC_PREFIX="sqlite:///"
SQLITE_ASYNC_PREFIX="sqlite+aiosqlite:///"
# First admin user — REQUIRED in every environment.
# Use a strong, unique password (>= 12 chars).
ADMIN_NAME="admin"
ADMIN_EMAIL="admin@example.com"
ADMIN_USERNAME="admin"
ADMIN_PASSWORD="REPLACE_WITH_STRONG_PASSWORD"
# CRUD Admin interface — disabled by default. Enable explicitly only when needed,
# and pair it with CRUD_ADMIN_ALLOWED_IPS_LIST.
CRUD_ADMIN_ENABLED=false
CRUD_ADMIN_MOUNT_PATH="/admin"
CRUD_ADMIN_ALLOWED_IPS_LIST=["127.0.0.1","::1"]
CRUD_ADMIN_MAX_SESSIONS=10
CRUD_ADMIN_SESSION_TIMEOUT=1440
SESSION_SECURE_COOKIES=true
CRUD_ADMIN_TRACK_EVENTS=true
CRUD_ADMIN_TRACK_SESSIONS=true
CRUD_ADMIN_REDIS_ENABLED=false
# CORS — explicit origins only. `*` is rejected in non-LOCAL environments.
CORS_ORIGINS=["http://localhost:3000","http://localhost:8000"]
CORS_METHODS=["GET","POST","PUT","PATCH","DELETE","OPTIONS"]
CORS_HEADERS=["Authorization","Content-Type","Accept"]
# Rate limiting (informational; the in-process limiter is a placeholder).
DEFAULT_RATE_LIMIT_LIMIT=10
DEFAULT_RATE_LIMIT_PERIOD=3600
# Client-side cache (seconds). Applied only to public, idempotent responses.
CLIENT_CACHE_MAX_AGE=60