Installation
Upgrading and rollback
Upgrade to a new version, what happens if an upgrade fails, and how to roll back.
New versions of Paybob are installed with one command. Every upgrade takes a full backup first, and if anything goes wrong, Paybob restores the backup and goes back to the version you had.
See what's new
System Settings → System Update in the panel shows your current version and, after a check, the newest version with its changelog. On a Docker installation the page shows the upgrade command instead of an install button, because upgrades run on the server. See System update.
Upgrade
Run the upgrade on your server:
sudo bash /opt/paybob/upgrade.shOr download the latest upgrade script first:
curl -fsSL https://get.paybob.io/upgrade.sh | sudo bashTo move to a specific version rather than the latest:
sudo bash /opt/paybob/upgrade.sh --version 3.0.2What happens during an upgrade
Download and verify
The upgrade downloads the new release's files and checks their checksums and signature, then downloads the new images and checks they're exactly the ones the release names. Your site keeps running during all of this.
Maintenance mode
Paybob switches to maintenance mode and stops background tasks, so nothing can change while the backup is taken. Customers see a short maintenance page during the next steps.
Backup
A full backup is written to /opt/paybob/backups/: the database, your data folder (uploads and packages) and your configuration.
Switch and update the database
Paybob switches to the new version, updates bundled gateways, themes and addons, and applies database changes.
Start and check
The new version starts and must report healthy within five minutes. Then maintenance mode ends.
When it's done, the upgrade prints the backup's location and the command to undo it.
Bundled packages are replaced with the new version's copies. Gateways, themes and addons you uploaded yourself are never touched.
If an upgrade fails
If any step after the backup fails, Paybob restores the backup automatically: it puts the previous version back, restores the database and files exactly as they were, and brings the site back online. No payment is lost, because nothing could be written between the backup and the restore.
If a step before the backup fails, nothing was changed, and the previous version simply comes back online.
The full log is in /opt/paybob/logs/.
Roll back
To go back to the state before an upgrade, restore its backup:
sudo bash /opt/paybob/upgrade.sh --rollbackWithout a name, --rollback uses the newest backup. To pick one, list them and pass its folder name:
ls /opt/paybob/backups
sudo bash /opt/paybob/upgrade.sh --rollback 20261003-091500-3.0.1-to-3.0.2A rollback loses newer data
A rollback restores the database as it was when the backup was taken. Payments, customers, settings and uploads recorded since then are lost. The rollback shows the backup's date and version and asks you to type rollback before it continues.
Backups
- A backup is taken before every upgrade, in
/opt/paybob/backups/. - The newest five are kept. Older ones are removed only after an upgrade succeeds.
- Backups on the server don't protect you if the server is lost. See Back up your data for your own backups.
Upgrade options
| Option | What it does |
|---|---|
--version VERSION | Upgrade to this version instead of the latest. |
--allow-downgrade | Allow moving to an older version. Without it, the upgrade refuses. |
--rollback [BACKUP] | Restore a backup instead of upgrading (default: the newest). Always asks first. |
--yes | Accept the prompts. A rollback still shows what it will lose. |
Upgrading a site that isn't on Docker
Installations that don't run on Docker are updated from the panel instead: System Settings → System Update → Check Updates → Download → Update Now. See System update.