The source code is on GitHub. Your server gets the same app as wirksam.app, in English and German.
This page is for people who look after a server, so it uses technical words and setting names.
What you need
- a server with Docker Engine and Docker Compose
- a domain whose DNS points at the server, most easily with a wildcard record
- ports 80 and 443 free for Traefik, which also fetches the HTTPS certificates from Let's Encrypt
- an SMTP account for email
Compose starts PostgreSQL, the backend, the frontend, Adminer and Garage as the file store. Traefik runs in front as its own stack.
The app runs at DOMAIN, the backend at API_DOMAIN, the file store at files.<DOMAIN> and Adminer at adminer.<DOMAIN>.
Keep
API_DOMAINunder the same domain as the app, such asapi.example.orgnext toexample.org. On an unrelated domain, signing in won't survive a page reload.
Start it with Docker Compose
Get the code and create the settings file:
git clone \
https://github.com/Blaxzter/wirksam.git
cd wirksam
cp .env.example .env
In .env, set at least:
ENVIRONMENT=production,DOMAIN,API_DOMAINandFRONTEND_HOST, the public address of the app.PROJECT_NAMEandSTACK_NAME. The project name is the sender name on emails.SECRET_KEYwith at least 32 bytes. Withchangethisor anything shorter, the backend won't start outsideENVIRONMENT=local.POSTGRES_PASSWORDwith a strong password, because Adminer is public. The stack would still start with theadminfrom.env.example.
Start Traefik first. It creates the traefik-net network the stack needs. It expects DOMAIN and EMAIL in the shell for the certificates, and USERNAME and HASHED_PASSWORD for its dashboard:
docker compose \
-f docker-compose.traefik.yml up -d
Then the app, without the override file for development:
docker compose \
-f docker-compose.yml up -d --build
Before the backend starts, the prestart container runs the database migrations. There's more in docs/deployment.md.
The first admin account
Without SUPERADMIN_EMAILS, a fresh install has no administrator. The setting is a JSON list:
SUPERADMIN_EMAILS=["[email protected]"]
Anyone who registers or signs in with one of these addresses gets the platform admin role. That role manages accounts under "User Management" and can open any event except demos. If you remove an address later, the account keeps its role.
The addresses in
SUPERADMIN_EMAILSget in under every registration mode and are approved straight away. So set them before you restrict signup.
Who may register
REGISTRATION_MODE has three values:
open(the default): anyone can sign up and use the account straight away. An account alone gives no access to any event.approval: anyone can sign up. The account waits until a platform admin approves it under "User Management".invite: only people with a valid event invitation can sign up. That means the invitation link or an open invitation to their own address.
REGISTRATION_ALLOWED_DOMAINS limits signup in any mode to certain email domains. Separate them with commas, such as gemeinde.de,example.org. Empty means any domain.
None of these settings apply to shared lists, because signing up on a list creates no account. To switch the lists off, see SHARED_LISTS_ENABLED in the questions below.
Where files live
People upload profile pictures, venue plan pictures and documents for team requests. STORAGE_BACKEND has two values:
s3is what.env.examplesets. WithCOMPOSE_PROFILES=s3, the bundled Garage container runs alongside. It creates the bucket and key on its first start, and you need a DNS record forfiles.<DOMAIN>.postgresputs the files in the database, with nothing else to run. This also applies if the variable is missing.
The backend won't start on the example key, so generate your own keys for a real install. The commands are in .env.example.
Email and reminders
For email, set SMTP_HOST, SMTP_USER, SMTP_PASSWORD and EMAILS_FROM_EMAIL. Add SMTP_PORT (default 587) and SMTP_TLS if you need them.
Without SMTP, links for verifying an address, resetting a password and invitations only go to the backend's log. Notifications by email are dropped. Signing in still works without a verified address.
The backend sends reminders itself, so you don't need a cron job for them. Browser push needs the VAPID_* keys, and Telegram a bot with TELEGRAM_BOT_TOKEN and TELEGRAM_BOT_USERNAME. Both are optional.