I noticed folks downloading some of these packages. I'm super grateful, Thank You! I would like to let folks know until this notice disappears I'm doing a lot of breaking changes without worrying about them. Once versions are up around 0.5.x things should settle down.
Backup and restore module for Pubvana CMS.
- PHP 8.1+
- Flight School ^0.3
- Flight Shield ^0.2
- Flight CSRF ^0.1
composer require pubvana/backupsEnable in app/config/config.php:
'plugins' => [
'pubvana/backups' => [
'enabled' => true,
'priority' => 50,
],
],- Full-site zip backups (configurable directories + database dump)
- Restore from any backup with automatic pre/post-rollback snapshots
- Retention policy (configurable max backups, default 15)
- Protected config files never overwritten during restore
- Dual-mode database operations (mysqldump/mysql CLI with pure PHP fallback)
- File-based progress reporting for admin UI polling
- Background execution via runway CLI with synchronous fallback
- Path traversal validation on zip extraction
This package uses Flight School's return-array config format. src/Config/Config.php returns the package defaults as an array, Flight School stores that array under pubvana.backups on $app.
Mapped as $app->backups(). Provides:
- Create - full-site zip (configurable dirs + database dump), with progress callback
- Restore - backup current state, extract, restore files + DB, backup restored state
- List/Delete/Download - manage stored backups
- Retention - automatically removes oldest backups beyond the configured limit
| Key | Default | Description |
|---|---|---|
backup_path |
PROJECT_ROOT . '/backups' |
Directory where backup zips are stored |
max_backups |
15 |
Maximum backups to keep |
backup_dirs |
['app', 'public', 'vendor', 'themes'] |
Directories included in the backup |
protected_configs |
['app/config/config.php', 'app/config/config_sample.php'] |
Files never overwritten during restore |
php runway backups:create
php runway backups:create --trigger pre-update --user admin
php runway backups:restore 2026-05-15_221300-full.zip
php runway backups:restore 2026-05-15_221300-full.zip --user adminMIT