New Desk versions are published to the Docker image ghcr.io/modelriver/desk and the GitHub repository. Updating is one command or a click, and every option can do it on a schedule.
What an update changes
- Your data stays. Articles, notes, settings, branding and conversations are untouched.
- The database updates itself. Any database changes run on their own when the new version starts.
- Back up before a big jump. Going back to an older version after its database has been updated isn't supported, so copy your data folder first.
- Major versions wait for you. The
1image tag follows every 1.x release, so a 2.x release never arrives on its own. To stay on one exact version, use its full tag, like1.0.1.
Update now, or on a schedule
| Where | Update now | On a schedule |
|---|---|---|
| Ubuntu server | sudo desk-update | A root cron entry that runs it (below) |
| Docker Compose | docker compose pull && docker compose up -d | A cron entry (below) |
| Fly.io | fly deploy | A scheduled job that runs fly deploy (below) |
| Render | Manual Deploy → Deploy latest reference | A scheduled job that calls the deploy hook |
| Railway | Redeploy | Settings → Image Auto Updates |
| By hand | git pull && npm ci && npm run build, then restart | A cron entry that runs it |
Weekly with cron (Docker Compose)
Every Monday at 04:00, in the folder with docker-compose.yml:
0 4 * * 1 cd /path/to/desk && docker compose pull -q && docker compose up -d
Add it with crontab -e. For a monthly update, use 0 4 1 * *.
Weekly with GitHub Actions (Fly.io)
Create a deploy token with fly tokens create deploy, save it as the repository secret FLY_API_TOKEN in a repository holding your fly.toml, and add .github/workflows/update-desk.yml:
1name: Update Desk2on:3 schedule:4 - cron: '0 4 * * 1'5 workflow_dispatch:6jobs:7 deploy:8 runs-on: ubuntu-latest9 steps:10 - uses: actions/checkout@v411 - uses: superfly/flyctl-actions/setup-flyctl@master12 - run: flyctl deploy --remote-only13 env:14 FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}The same schedule can call Render's deploy hook instead: replace the last two steps with run: curl -fsS -X POST "${{ secrets.RENDER_DEPLOY_HOOK }}" and save the hook URL as RENDER_DEPLOY_HOOK.
Ubuntu server
setup-server.sh installs desk-update, which updates to a release without any options to remember:
sudo desk-update --check # what's installed, and what's outsudo desk-update # the newest release of the major version you runsudo desk-update 1.1.1 # a given release, newer or oldersudo desk-update --rollback # back to the version before the last updateEach update:
- Backs up
/var/lib/deskand/etc/deskto/var/backups/desk, with a consistent copy of the database taken while Desk keeps running. The last 3 are kept. - Builds the new release beside the running one, in
/opt/desk.next. If the download or build fails, it stops there and nothing changes. - Switches over and restarts, a few seconds of downtime. The version you had is kept as
/opt/desk.prev. - Checks it answers. If the new version doesn't respond within 30 seconds, it switches back on its own.
Releases come from the repository you installed from. A new major version waits until you name it. Settings, data, nginx and HTTPS are never touched.
Weekly, every Monday at 04:00, with sudo crontab -e:
0 4 * * 1 /usr/local/bin/desk-update
To restore a backup, unpack it into an empty folder (never over /) and copy it back with Desk stopped. Removing the old database's -wal and -shm files keeps them from being replayed onto the restored copy:
sudo systemctl stop desksudo mkdir /tmp/desk-restore && sudo tar -xzf /var/backups/desk/FILE.tgz -C /tmp/desk-restoresudo rsync -a /tmp/desk-restore/var/lib/desk/ /var/lib/desk/sudo rm -f /var/lib/desk/desk.db-wal /var/lib/desk/desk.db-shmsudo install -o desk -g desk -m 640 /tmp/desk-restore/desk.db /var/lib/desk/desk.dbsudo systemctl start deskThe archive also holds etc/desk/env, if you need your settings back.
An install from before Desk 1.1.2 doesn't have desk-update yet. Get it once from your copy of the repository, then use it from then on:
cd ~/desk && git pull && sudo install -m 755 deploy/update.sh /usr/local/bin/desk-updateAfter updating
Open Dashboard → Settings → System (admins only): it shows the version that's running. General shows whether ModelRiver is reachable.