Upgrading
Pull, rebuild, restart. The database schema is updated on start.
Self-hosted only
senlo.io is upgraded for you.
cd senlo
git pull
cd deploy/vps
docker compose up -d --buildThat is the whole upgrade. When the new app container starts it:
- applies the database schema with
pnpm db:push(Drizzle; there are no separate migration files to run); - creates any users from
INITIAL_USERSthat do not exist yet; - starts the app.
The worker container is rebuilt from the same image and restarted with it.
Before you upgrade
- Back up the database (see Production checklist).
db:pushchanges the schema in place. - Read the release notes on GitHub for steps a version needs, such as a new required variable.
After you upgrade
docker compose ps # app, worker, db, redis are up
docker compose logs -f app # "Starting Senlo..." and no config errorsIf the app refuses to start with "Senlo is not configured correctly", the log lists the variables to fix. See Configuration.
One-time steps from older versions
- Before API keys were hashed: keys keep working; run
docker compose exec app pnpm db:hash-api-keysto replace stored keys with their hashes. - Before
SECRETS_KEYexisted: provider credentials are encrypted withAUTH_SECRET. Give them their own key: addSECRETS_KEY, restart, thendocker compose exec -e OLD_SECRETS_KEY="<your AUTH_SECRET>" app pnpm db:reseal-secrets. - Before the reverse-proxy requirement: the app now listens on
127.0.0.1:3000only, sohttp://your-server:3000stops answering. Put a proxy in front, or setAPP_BIND=0.0.0.0:3000for now.
Rolling back
Check out the previous version and rebuild:
git checkout <previous-tag-or-commit>
docker compose up -d --builddb:push does not undo schema changes. If the new version changed the schema, restore the backup taken before the upgrade.