Skip to content

Commit

Permalink
rename pre/post/backup-failure-hook to -command
Browse files Browse the repository at this point in the history
This change is meant to be more compatible with holland 2.0
which has a more sophisticated notion of a hook and to more
clearly note that these "hooks" are just running shell commands
  • Loading branch information
abg committed May 3, 2012
1 parent 739dbe4 commit d424af5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion holland/commands/backup.py
Expand Up @@ -122,7 +122,7 @@ def purge_backup(event, entry):
LOG.info("auto-purge-failures not enabled. Failed backup not purged.")

def call_hooks(event, entry):
hook = event + "-hook"
hook = event + "-command"

if entry.config['holland:backup'][hook] is not None:
cmd = entry.config['holland:backup'][hook]
Expand Down
6 changes: 3 additions & 3 deletions holland/core/spool.py
Expand Up @@ -222,9 +222,9 @@ def __cmp__(self, other):
backups-to-keep = integer(min=0, default=1)
auto-purge-failures = boolean(default=yes)
purge-policy = option(manual, before-backup, after-backup, default='after-backup')
post-backup-hook = string(default=None)
pre-backup-hook = string(default=None)
backup-failure-hook = string(default=None)
post-backup-command = string(default=None)
pre-backup-command = string(default=None)
backup-failure-command = string(default=None)
""".splitlines()

class Backup(object):
Expand Down

0 comments on commit d424af5

Please sign in to comment.