\Alddesign\Crudkit\ClassesBackup

Functionallity for automated folder backups as .zip files.

Usage: define backup types and paths in config/crudkit.php. Setup an external cronjob to call the backup url. All errors make the script abort by sending a HTTP 500 error plus an error message as an result.

Summary

Methods
Properties
Constants
__construct()
cleanupBackupDir()
createBackup()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
$sourceFolder
$destinationFolder
$maxBackupFiles
$extension
N/A

Properties

$sourceFolder

$sourceFolder : 

Type

$destinationFolder

$destinationFolder : 

Type

$maxBackupFiles

$maxBackupFiles : 

Type

$extension

$extension : 

Type

Methods

__construct()

__construct(string  $sourceFolder, string  $destinationFolder, integer  $maxBackupFiles) : void

Constructor. Returns http 500 on failure.

Parameters

string $sourceFolder

The folder to back up

string $destinationFolder

The location for the backup .zip file

integer $maxBackupFiles

Max. amount ouf backup files in the backup folder

cleanupBackupDir()

cleanupBackupDir() : void

Removes the oldest files from the directory. Returns http 500 on failure.

createBackup()

createBackup() : void

Creates the .zip Backup file. Returns http 500 on failure.