Allow external Postgres URL

This commit is contained in:
Zachariah K. Sharma
2026-06-05 23:53:54 -06:00
parent e6f1c5c13f
commit d142603c12
4 changed files with 42 additions and 28 deletions
+10 -5
View File
@@ -17,9 +17,7 @@ The app container runs `prisma migrate deploy` before starting the Next.js stand
```bash
APP_PORT=3000
POSTGRES_DB=formbuilder
POSTGRES_USER=formbuilder
POSTGRES_PASSWORD=replace-with-a-strong-password
DATABASE_URL=postgresql://user:password@postgres-host:5432/formbuilder
AUTH_SECRET=replace-with-openssl-rand-base64-32
AUTH_URL=https://forms.example.com
@@ -34,6 +32,12 @@ [email protected]
Optional values are documented in `.env.example` for Redis rate limiting, email, file storage, hCaptcha, and webhook worker auth.
If you do not already have Postgres, deploy with both Compose files and set `POSTGRES_PASSWORD`:
```bash
docker compose -f docker-compose.yml -f docker-compose.postgres.yml up --build
```
## Authentik Setup
Create an OAuth2/OpenID provider in Authentik:
@@ -50,11 +54,12 @@ The first successful signer becomes an admin. Any emails listed in `AUTH_BOOTSTR
## Persistent Data
The compose stack creates two named volumes:
The default compose stack creates one named volume:
- `postgres_data`: Postgres database
- `uploads`: local uploaded files mounted at `/app/uploads`
When using `docker-compose.postgres.yml`, it also creates `postgres_data` for the bundled database.
For multi-instance deployments, set `RATE_LIMIT_DRIVER=redis` and provide `REDIS_URL`. For durable object storage outside the app container, configure the S3 values in `.env.example`.
## Useful Commands