PHP Classes

Backup Task: Take backups of directories and MySQL databases

Recommend this page to a friend!
  Info   View files View files (23)   DownloadInstall with Composer Download .zip   Reputation   Support forum (1)   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2024-01-09 (4 days ago) RSS 2.0 feedNot enough user ratingsTotal: 689 This week: 5All time: 4,729 This week: 62Up
Version License PHP version Categories
backup-task 1.0.9BSD License5.3PHP 5, Databases, Files and Folders, S...
Description 

Author

This package can take backups of directories and MySQL databases.

It provides a generic interface to execute backup tasks, upload the backup data to somewhere safe, and notify that the backup tasks finished successfully.

There are different classes that actual implement the backup process for files in directories and MySQL databases.

The backup process creates tar.gz files with the backup data.

The upload step may transfer the backup file to another directory or to a remote server via FTP.

The notification step sends an e-mail with the results of the whole process.

Picture of Alexey Freelancer
Name: Alexey Freelancer <contact>
Classes: 2 packages by
Country: Ukraine Ukraine

Details

# BackupTask can help you to backup your directories and databases Create directories and databases backup, upload it to local directory or to ftp and send notification email with detail statistics. ## Requirements * PHP 5.3-7.2 * Unix OS ## Installation ### Download library git clone git://github.com/AlexeyFreelancer/BackupTask.git git clone git://github.com/symfony/ClassLoader.git ### Configure cp ./BackupTask/config.dist.php config.php Change settings in config.php ### Usage Create new file backup.php with following code <?php require_once 'ClassLoader/ClassLoader.php'; use Symfony\Component\ClassLoader\ClassLoader; $loader = new ClassLoader(); $loader->register(); $loader->addPrefix('BackupTask', __DIR__); $config = include 'config.php'; $backupTask = new BackupTask\BackupTask($config); try { $backupTask->run(); } catch (Exception $e) { echo $e->getMessage(); } ### Configure cron job @daily /usr/bin/php /path/to/backup.php daily @weekly /usr/bin/php /path/to/backup.php weekly @monthly /usr/bin/php /path/to/backup.php monthly

  Files folder image Files  
File Role Description
Files folder imageCommand (3 directories)
Plain text file BackupTask.php Class Class source
Accessible without login Plain text file config.dist.php Conf. Configuration script
Accessible without login Plain text file example.php Example example
Accessible without login Plain text file README.md Data Auxiliary data

  Files folder image Files  /  Command  
File Role Description
Files folder imageBackup (4 files)
Files folder imageNotification (3 files, 1 directory)
Files folder imageUpload (4 files)

  Files folder image Files  /  Command  /  Backup  
File Role Description
  Plain text file BackupAbstract.php Class Class source
  Plain text file BackupCommand.php Class Class source
  Plain text file DirectoryBackup.php Class Class source
  Plain text file MysqlBackup.php Class Class source

  Files folder image Files  /  Command  /  Notification  
File Role Description
Files folder imageemail_templates (2 files, 1 directory)
  Plain text file EmailNotification.php Class Class source
  Plain text file NotificationAbstract.php Class Class source
  Plain text file NotificationCommand.php Class Class source

  Files folder image Files  /  Command  /  Notification  /  email_templates  
File Role Description
Files folder imagecomponents (6 files)
  Accessible without login Plain text file failed.php Example Example script
  Accessible without login Plain text file success.php Example Example script

  Files folder image Files  /  Command  /  Notification  /  email_templates  /  components  
File Role Description
  Accessible without login Plain text file archive_stats.php Example Example script
  Accessible without login Plain text file common_stats.php Example Example script
  Accessible without login Plain text file directory_stats.php Example Example script
  Accessible without login Plain text file directory_upload_stats.php Example Example script
  Accessible without login Plain text file ftp_upload_stats.php Example Example script
  Accessible without login Plain text file mysql_stats.php Example Example script

  Files folder image Files  /  Command  /  Upload  
File Role Description
  Plain text file DirectoryUpload.php Class Class source
  Plain text file FtpUpload.php Class Class source
  Plain text file UploadAbstract.php Class Class source
  Plain text file UploadCommand.php Class Class source

 Version Control Unique User Downloads Download Rankings  
 100%
Total:689
This week:5
All time:4,729
This week:62Up
User Comments (1)
Excelent class, you as a big know how ! :-)
11 years ago (José Filipe Lopes Santos)
70%StarStarStarStar