PSAPLink Cloud — Setup
PSAPLink Cloud is the hub. Handles notification routing, company dashboards, and the superadmin console.
Prerequisites
- PHP 8.2+ / Composer 2.x
- PostgreSQL 15+
- Node.js 20+ (React frontend)
- Docker & Docker Compose (recommended)
Quick Start
cd cloud
cp .env.example .env.local
./dev-up.sh --fresh
--fresh drops the DB, re-migrates, and loads seed fixtures. Omit on subsequent starts.
Key Environment Variables
| Variable | Description |
|---|---|
DATABASE_URL | PostgreSQL connection string |
JWT_SECRET_KEY / JWT_PUBLIC_KEY | Paths to RSA key pair |
JWT_PASSPHRASE | Private key passphrase |
MERCURE_JWT_SECRET | Shared Mercure SSE secret |
LIBSODIUM_ENCRYPTION_KEY | 32-byte hex key (field-level encryption) |
LIBSODIUM_ENCRYPTION_KEY_VERSION | v1 default |
Generate JWT Keys
php bin/console lexik:jwt:generate-keypair
Generate Encryption Key
openssl rand -hex 32
Store the output in .env.local as LIBSODIUM_ENCRYPTION_KEY.
Start the Messenger Worker
Notifications are dispatched asynchronously — the worker must be running:
php bin/console messenger:consume async --time-limit=3600
In production this runs as a Docker service with auto-restart.
Dev Seed Credentials
| Role | Password | |
|---|---|---|
| superadmin | superadmin@psaplink.local | password |
| psap_admin | psap@example.local | password |
| company_admin | company@example.local | password |
warning
Dev credentials only — never use in production.