Skip to content

Commit

Permalink
update documentation for before/after/failed backup commands
Browse files Browse the repository at this point in the history
  • Loading branch information
abg committed Jan 9, 2013
1 parent cdffeed commit 8857808
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions docs/source/config.rst
Expand Up @@ -143,7 +143,7 @@ put the following at the top of the backup set configuration file::
Either ``holland purge`` must be run externally or an explicit removal of Either ``holland purge`` must be run externally or an explicit removal of
desired backup directories can be done at some later time. desired backup directories can be done at some later time.


**pre-backup-command** = string **before-backup-command** = string


Run a shell command before a backup starts. This allows some command to Run a shell command before a backup starts. This allows some command to
perform some action before the backup starts such as setting up an perform some action before the backup starts such as setting up an
Expand All @@ -154,7 +154,7 @@ put the following at the top of the backup set configuration file::


.. versionadded:: 1.0.7 .. versionadded:: 1.0.7


**post-backup-command** = string **after-backup-command** = string


Run a shell command before a backup starts. This allows some command to Run a shell command before a backup starts. This allows some command to
perform some action when a backup completes successfully such as sending perform some action when a backup completes successfully such as sending
Expand All @@ -164,7 +164,7 @@ put the following at the top of the backup set configuration file::


.. versionadded:: 1.0.7 .. versionadded:: 1.0.7


**backup-failure-command** = string **failed-backup-command** = string


Run a shell command before a backup starts. This allows some command to Run a shell command before a backup starts. This allows some command to
perform some action when a backup fails such as sending out a failure perform some action when a backup fails such as sending out a failure
Expand All @@ -176,16 +176,16 @@ put the following at the top of the backup set configuration file::
For all hook commands, Holland will perform simple text substitution substitution For all hook commands, Holland will perform simple text substitution substitution
on the three parameters: on the three parameters:


* hook - name of the hook being called (one of: pre-backup-command, post-backup-command, backup-failure-command) * hook - name of the hook being called (one of: before-backup-command, after-backup-command, failed-backup-command)
* backupdir - path to the current backup directory (e.g. /var/spool/holland/mysqldump/YYYYmmdd_HHMMSS) * backupdir - path to the current backup directory (e.g. /var/spool/holland/mysqldump/YYYYmmdd_HHMMSS)
* backupset - name of the backupset being run (e.g. 'mysql-lvm') * backupset - name of the backupset being run (e.g. 'mysql-lvm')


For example:: For example::
[holland:backup] [holland:backup]
plugin = mysqldump plugin = mysqldump
pre-backup-command = /usr/local/bin/my-custom-script --hook ${hook} --backupset ${backupset} --backupdir ${backupdir} before-backup-command = /usr/local/bin/my-custom-script --hook ${hook} --backupset ${backupset} --backupdir ${backupdir}
post-backup-command = echo ${backupset} completed successfully. Files are in ${backupdir} after-backup-command = echo ${backupset} completed successfully. Files are in ${backupdir}
[mysqldump] [mysqldump]
... ...
Expand Down

0 comments on commit 8857808

Please sign in to comment.