Swush
Getting Started

Environment

Core env vars and how to set them.

Copy example.env to .env, then update values:

cp example.env .env

Core

APP_NAME="Swush"
APP_URL="http://localhost:3000"
CORS_ORIGIN="http://localhost:3000"
SUPPORT_NAME="Support"
SUPPORT_EMAIL="help@swush.app"

Database

DATABASE_URL="postgresql://user:pass@host:port/dbname"

Auth and Security

BETTER_AUTH_URL="http://localhost:3000"
BETTER_AUTH_SECRET="some-32-random-secret"

Storage I Local

STORAGE_DRIVER="local" # or "s3"
UPLOAD_ROOT="./data/uploads" # if using local storage

Storage II S3-compatible

STORAGE_DRIVER="s3"
S3_ENDPOINT="https://s3.example.com"
S3_REGION="us-east-1"
S3_BUCKET="my-bucket"
S3_ACCESS_KEY="your-access-key"
S3_SECRET_KEY="your-secret-key"
S3_FORCE_PATH_STYLE=true

Email

SMTP_HOST="smtp.example.com"
SMTP_PORT=587
SMTP_USER="smtp-user"
SMTP_PASS="smtp-pass"
SMTP_FROM="Swush <support@swush.app>"

VAPID (for push notifications)

VAPID_PUBLIC_KEY="your-vapid-public-key"
VAPID_PRIVATE_KEY="your-vapid-private-key"
VAPID_SUBJECT="mailto:your-email@example.com"

FFMpeg and YT-DLP paths (if not in system PATH)

FFMPEG_PATH="/usr/bin/ffmpeg"
YT_DLP_PATH="/usr/bin/yt-dlp"

External APIs

TMDB_API_KEY="your-tmdb-api-key"
RAWG_API_KEY="your-rawg-api-key"
STEAM_API_KEY="your-steam-api-key"
STEAM_LINK_SECRET="your-steam-link-secret"
ANILIST_CLIENT_ID="your-anilist-client-id"
ANILIST_CLIENT_SECRET="your-anilist-client-secret"

Cron

CRON_SECRET="your-cron-secret"
ENABLE_APP_CRON=true
STREAM_JOBS_QUEUE_LIMIT=15
STREAM_JOBS_CONCURRENCY=5

For the complete list and defaults, see example.env, which is also the source of truth for env vars in the app and Docker setup.

On this page