dvixi / phpbu
PHP Backup utility.
Requires
- ext-dom: *
- ext-json: *
- ext-spl: *
- phpunit/php-timer: ~1.0.2
- sebastian/environment: ~1.1
- sebastian/version: ~1.0
- swiftmailer/swiftmailer: ~5.3
- symfony/event-dispatcher: ~2.6
Requires (Dev)
- aws/aws-sdk-php: ~3.10
- dropbox/dropbox-sdk: ~1.1
- phpseclib/phpseclib: ~2.0
- softlayer/objectstorage: dev-master
Suggests
- aws/aws-sdk-php: Require '~3.10' to sync to Amazon S3
- dropbox/dropbox-sdk: Require '~1.1' to sync to Dropbox
- phpseclib/phpseclib: Require '~2.0' to use SFTP sync
- softlayer/objectstorage: Require 'dev-master' to sync to Softlayer
This package is not auto-updated.
Last update: 2024-11-15 19:06:23 UTC
README
PHP Backup Utility
PHPBU is a php framework that creates and encrypts backups, syncs your backups to other servers or cloud services and assists you monitor your backup creation.
Get detailed information about all the features and a 'getting started' tutorial at the PHPBU Website.
Features
- Creating backups
- ArangoDB
- Directories
- Elasticsearch
- MongoDB
- MySQL
- Percona XtraBackup
- PostgreSQL
- Redis
- Validate backups
- Check min size
- Comparing with previous backups
- Encrypting backups
- mcrypt
- openssl
- Sync backups to other locations
- Amazon s3
- Dropbox
- rsync
- SFTP
- FTP
- Softlayer
- Cleanup your backup location
- Delete backups older x
- Store only x MB of backups
- Keep only last x backups
Requirements
- PHP 5.4+
- ext/curl
- ext/dom
- ext/json
- ext/spl
- POSIX Shell
- tar
- bzip2 or gzip
Installation
You can download a PHP Archive (PHAR) that bundles everything you need to run PHPBU in a single file.
wget http://phar.phpbu.de/phpbu.phar
chmod +x phpbu.phar
php phpbu.phar --version
For convenience, you can move the PHAR to a directory that is in your PATH.
mv phpbu.phar /usr/local/bin/phpbu
phpbu --version
Installing PHPBU via Composer is also supported.
"require": { "phpbu/phpbu": "3.1.*" }
Usage
phpbu [option]
--bootstrap=<file> A "bootstrap" PHP file that is included before the backup.
--configuration=<file> A phpbu xml config file.
--colors Use colors in output.
--debug Display debugging information during backup generation.
--simulate Perform a trial run with no changes made.
-h, --help Print this usage information.
-v, --verbose Output more verbose information.
-V, --version Output version information and exit.
Usage Examples
$ phpbu
This requires a valid XML PHPBU configuration file (phpbu.xml or phpbu.xml.dist) in your current working directory. Alternatively, you can specify the path to your configuration file.
$ phpbu --configuration=backup/config.xml
Configuration
Simple configuration example:
<?xml version="1.0" encoding="UTF-8"?> <phpbu xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://schema.phpbu.de/3.1/phpbu.xsd" verbose="true"> <backups> <backup> <!-- source --> <source type="mysqldump"> <option name="databases" value="mydbname"/> <option name="user" value="user.name"/> <option name="password" value="topsecret"/> </source> <!-- where should the backup be stored --> <target dirname="backup/mysql" filename="mysqldump-%Y%m%d-%H%i.sql" compress="bzip2"/> </backup> </backups> </phpbu>