35 lines
1016 B
Bash
35 lines
1016 B
Bash
# Copy to .env and adjust. Every value here can also be supplied as a real
|
|
# environment variable (which takes precedence over the .env file).
|
|
|
|
# --- General ---
|
|
APP_NAME="FastAPI Skeleton"
|
|
DEBUG=false
|
|
|
|
# --- Security ---
|
|
# Generate a strong value, e.g. `python -c "import secrets; print(secrets.token_urlsafe(48))"`
|
|
SECRET_KEY="change-me-please-use-a-long-random-string"
|
|
ALGORITHM=HS256
|
|
ACCESS_TOKEN_EXPIRE_MINUTES=15
|
|
REFRESH_TOKEN_EXPIRE_DAYS=7
|
|
|
|
# --- Database ---
|
|
# SQLite (zero-setup default):
|
|
DATABASE_URL="sqlite+aiosqlite:///./app.db"
|
|
# Postgres example:
|
|
# DATABASE_URL="postgresql+asyncpg://app:app@localhost:5432/app"
|
|
|
|
# Create tables on startup (handy for dev/SQLite; use Alembic in production).
|
|
AUTO_CREATE_TABLES=true
|
|
|
|
# --- Web / cookies ---
|
|
COOKIE_NAME=access_token
|
|
# Set true when serving over HTTPS.
|
|
COOKIE_SECURE=false
|
|
|
|
# --- CORS (JSON list) ---
|
|
CORS_ORIGINS=["*"]
|
|
|
|
# --- Bootstrap superuser (used by scripts/seed.py) ---
|
|
FIRST_SUPERUSER_EMAIL=admin@example.com
|
|
FIRST_SUPERUSER_PASSWORD=changethis
|