PegasusGate
Menu
PegasusGate
Home
Squirrels Hate Robots
Nut Driven Development
Bob Majdak Jr
PHP Developer
Projects
Log In
Dark / Light
Projects
Back
Ashbox
SSL Cert Management
Backup Here Device
Simple Backup Tool
VSCode Dashboard
Project Management Tool
Nether Atlantis
Prototype Framework Project
Backup Here Device
Manage backups of directories, git repos, and databases.
Requirements
PHP 8.1+
Composer for PHP
rsync
for directory backup.
git
for repository backup.
ssh
for tunneled database backup.
mysqldump
for db backup if not
ssh
tunneling to host with it.
GitHub
Install From Source
$ git clone https://github.com/bobmagicii/bhd
$ cd bhd
$ composer install
Projects
Start a new project named "example".
$ bhd new example
Directories
Add a new directory to back up.
$ bhd dir example website.tld:/path/to/app
Remove the directory.
$ bhd dir example --del website.tld:/path/to/app
Repositories
Add a new git repo to back up.
$ bhd repo example website.tld:/path/to/app
Remove the repo.
$ bhd repo example --del website.tld:/path/to/app
Databases
Add a new MySQL database to back up.
$ bhd db example --db=ExampleDB --tunnel=website.tld --user=exuser --pass=expass
Remove the database.
$ bhd db example --del --db=ExampleDB
Running The Backups
Run the example project.
$ bhd run example
Run all projects that need it. This is what you add to crontab.
$ bhd autorun