Skip to Content
Payload Bay

Single-container deployment

deploy/compose.single.yml runs Payload Bay as one application container plus PostgreSQL.

deploy/compose.single.yml runs Payload Bay as one application container plus PostgreSQL. The container holds the web server and the worker; either process ending stops the other, so the container restarts as a unit and never serves requests without a worker. It builds from source with public dependencies and needs no registry credentials, so any Docker host or a platform such as Coolify can run it.

This is an alpha path. Read the limits before using it.

What works and what does not

FeatureSingle container
Stable ingress URL per source, raw body and headers stored before the 2xxYes
Forwarding to health-checked targets, failover, queueing, replayYes, see forwarding
Attempt inspection and manual replayYes
Scripted ingress and processing (sandboxed executor)No. The executor is not part of this image
Outbound runner and fan-outNot available yet

Scripted endpoints need the full operator installation, which adds the executor. Forwarding endpoints do not use it.

Configure

Set these as environment variables or in an env file kept outside Git.

SettingPurpose
PUBLIC_URLExternal HTTPS origin used for links and sign-in
POSTGRES_PASSWORDDatabase password
BETTER_AUTH_SECRET, PAYLOADBAY_ENCRYPTION_KEY, PAYLOADBAY_BOOTSTRAP_SECRETIndependent secrets of at least 32 characters. Keep the encryption key with your backups: stored target headers and secrets cannot be read without it
EMAIL_FROMSender address, on a domain you control and have verified. SMTP_FROM is the older name and is still accepted
USESEND_BASE_URL, USESEND_API_KEYSend through a useSend server's HTTP API. Selected when the key is set, and takes precedence over SMTP
SMTP_HOST, SMTP_PORT, SMTP_SECURE, SMTP_USER, SMTP_PASSWORDSend through any SMTP server instead. SMTP_SECURE is true for implicit TLS (usually port 465) and false for STARTTLS (usually port 587)

Configure exactly one email transport. Sign-in uses one-time codes sent by email, so mail delivery is required. The useSend path checks that the server is reachable but cannot check the key without sending a message; a wrong key shows up as a failed send. A complete, commented example is in .env.example.

Generate each secret with openssl rand -hex 24.

Registration is invitation-only by default. The first owner is created with the one-time bootstrap secret, see bootstrap.

Run

docker compose --env-file /secure/payloadbay.env -f deploy/compose.single.yml up -d --build

Put a TLS-terminating reverse proxy in front of port 3000 of the payload-bay service. On Coolify, create a Docker Compose application from this repository, select deploy/compose.single.yml, set the variables above, and assign your domain to the payload-bay service on port 3000. The postgres and schema services need no domain.

The container reports healthy once the web server answers. The compose file sets a read-only root filesystem, drops all capabilities and disables privilege escalation.

Schema and upgrades

Release migrations are generated by the master CI workflow and are not part of this source-built path yet. The schema service therefore applies the schema only to an empty database. On a database that is already initialized it logs that it skipped the step and changes nothing, so redeploying never alters or drops existing data.

The consequence: pulling a newer version that changes the schema does not upgrade an existing instance. Before upgrading across a schema change, take a backup (see backup) and apply a reviewed migration, or start a fresh database and restore the data you need. Do not run the development push against an instance that holds data: it is not idempotent and can plan destructive changes.

Backup

The data lives in the postgres volume. Back it up with the procedure in backup, together with the encryption key.

Edit on GitHub

On this page