\pm_Hook_Backup_Domain

Hook for backing up and restoring domains

Summary

Methods
Properties
Constants
postBackup()
backup()
restore()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A

Methods

postBackup()

postBackup(\pm_Domain  $domain) 

Define the logic after backing up a domain

Parameters

\pm_Domain $domain

The domain that is backuped

backup()

backup(\pm_Domain  $domain) : array

Define the content to be stored

[
    string, // Serialized config related to this domain
    array,  // Array of relative paths inside extension's 'var' directory that will be include in backup
    array,  // Array of relative paths inside extension's 'var' directory that will be exclude from backup
    array,  // Array of relative paths inside webspace root is marked as 'mine' content by the extension .
               These paths will be completely overwritten during restore.
               If the extension is absent on the server, this paths will not be restored.
]

Parameters

\pm_Domain $domain

The domain that is backuped

Returns

array

restore()

restore(\pm_Domain  $domain, string  $pleskVersion, string  $extVersion, string  $config, string  $contentDir) 

Define logic on restore domain

Parameters

\pm_Domain $domain

The domain that is restored

string $pleskVersion

Version of Plesk when backup was created

string $extVersion

Version of extension when backup was created

string $config

Stored config related to restoring domain

string $contentDir

Directory with content related to restoring domain