Payload CMS backend for the accessibility site.
Create a local .env file from the example:
cp .env.example .envAdjust values as needed. At minimum, set a real PAYLOAD_SECRET before using
the environment for anything shared.
Copy the media directory from a running instance, or create an empty one for
a fresh local setup:
mkdir -p mediaActivate the development environment and start services:
flox activate -sThe activation hook initializes PostgreSQL on first use and creates the local database if it does not exist.
pnpm installLocal development uses the pnpm package provided by Flox. Production image
builds use Corepack inside the Dockerfile, so Docker resolves pnpm from the
packageManager field in package.json.
For a fresh empty local setup, this step can be skipped. To restore a database dump from another instance:
pg_restore -d "${PGDATABASE}" --no-owner payload.dumpCreate that dump on the source instance with:
pg_dump -Fc -d "${PGDATABASE}" -f payload.dumppnpm devUseful commands:
pnpm build
pnpm generate:types
pnpm generate:importmapflox upgrade toplevelExit the active Flox shell, then activate it again so updated tools and services are used:
exit
flox activate -sAfter confirming the upgraded environment works, remove old Flox package installs:
flox gcKeep the packageManager version in package.json aligned with the pnpm version
from Flox. This keeps local installs and Docker image builds on the same pnpm
major version:
pnpm --versionIf the Node.js major version changes, update the Dockerfile base image to match
the Flox Node.js major version. For example, nodejs_24 in Flox should use
node:24-alpine in Dockerfile.