Parameters
Parameter reference
string
default:"fullstack"
Execution mode.
integer
default:"3000"
Port the API server listens on.
3000 (default) · 8080This applies when running from source. Both Docker Compose profiles publish
3000:3000 without passing PORT through, and in the full image the API is
pinned to an internal port behind nginx, so setting PORT there either does
nothing or breaks the published mapping. To change the exposed port in Docker,
edit the port mapping instead.string
required
Secret used by Better Auth to sign sessions and tokens. Use at least 32 characters. Startup fails only when it is unset or left at the build placeholder; a shorter value logs a warning and keeps running, so treat the length as your responsibility rather than an enforced check.
string
default:"http://localhost:3000"
Public base URL of your Openinary instance. Used for auth callbacks and CORS.
http://localhost:3000 · https://media.example.comstring
default:"http://localhost:3000"
Public base URL the browser uses to reach the API. Like
BETTER_AUTH_URL, this defaults to your instance’s single public URL, set it once and both point at the same place.http://localhost:3000 · https://media.example.comIn the bundled
full Docker Compose profile (API + web + nginx behind one port), this is baked in as /api at build time since nginx already proxies the API under that path, you don’t need to set it yourself. Set it explicitly when the API is reachable at a different origin, e.g. an api profile deployment or an external frontend embedding the File Uploader.string
Allowed origins when Openinary is called from a separate frontend. Accepts several, separated by commas. Only set this in production:
http://localhost:3001 (the dashboard in dev) and http://localhost:3000 are always allowed on top of whatever you set here.https://yourapp.com · https://app.example.com,https://admin.example.comstring
Secret used to sign and verify signed URLs and presigned, authenticated uploads (see the File Uploader). Required if you use the
/authenticated/* route or presigned uploads. Must be at least 16 characters. openssl rand -hex 32 gives you a strong 64-character secret.string
default:"/app/data/auth.db"
Custom path for the SQLite database. Only needed when mounting to a non-standard location.
/app/data/auth.db · /mnt/volume/openinary.dbAdmin bootstrap
These run only on the very first boot, while the user table is still empty. Once an account exists they are ignored, so you cannot use them to reset a password or add a second admin. Without them, afullstack instance logs a line telling you to visit /setup and waits for you to create the account in the browser. Set them when you need an unattended deployment.
string
Email of the admin account to create on first boot.
string
Password for that account.
string
default:"Admin"
Display name for the account.
boolean
default:"false"
Create an API key alongside the admin account and print it to the container
logs. Must be the exact string
true.In fullstack mode this requires the admin credentials above, otherwise
startup stops with a message saying so. In api mode a key is generated on
first boot regardless of this setting, since an API-only instance would
otherwise have no way in.Logging and advanced
string
default:"info in production, debug in development"
Log verbosity:
trace, debug, info, warn, error or fatal.boolean
default:"false"
Lets a request supply its source bytes from an HTTPS URL via the
x-openinary-source-url header, instead of from this instance’s storage.
Must be the exact string true.string
Base URL used for server-to-server auth calls inside the container, so they
skip the public hostname and the proxy in front of it. The bundled
full
profile sets this for you.string
Origin the dashboard builds delivery URLs against, when media is served from a
CDN domain that differs from the API.
string
Log verbosity for the dashboard’s browser-side logger.
string
default:"latest"
Docker image tag the Compose file pulls. Pin it to a release such as
v0.3.1
to keep deployments reproducible.Upload
integer
default:"50"
Maximum allowed file size for uploads, in megabytes.
50 (default) · 500 · 2048Useful for self-hosted setups where users need to upload large video files. Set it in your
.env file or Docker environment, no image rebuild required. This is the only upload ceiling: the full image’s nginx passes bodies through without a limit of its own, so whatever you set here is what applies.Rate limiting
Rate limiting applies to all public routes (/t/*, /download/*, /health, etc.).
integer
default:"100"
Maximum requests per window.
100 (default) · 200 (high traffic) · 50 (strict)integer
default:"60000"
Window duration in milliseconds.
Related
Storage
Connect S3-compatible cloud storage.
Signed URLs
Use
API_SECRET to sign transformation URLs.