diff options
author | Damien Lallement <dams@mageia.org> | 2011-03-30 09:29:10 +0000 |
---|---|---|
committer | Damien Lallement <dams@mageia.org> | 2011-03-30 09:29:10 +0000 |
commit | ef6a35a31b4ea311184d4091f053ebe167eba2cf (patch) | |
tree | d364161a8198ad2feb90d1dcc265c1f7a2d4cc27 /modules/blog | |
parent | ae7ea36f745d70b5665a2190ad316756310315bd (diff) | |
download | puppet-ef6a35a31b4ea311184d4091f053ebe167eba2cf.tar puppet-ef6a35a31b4ea311184d4091f053ebe167eba2cf.tar.gz puppet-ef6a35a31b4ea311184d4091f053ebe167eba2cf.tar.bz2 puppet-ef6a35a31b4ea311184d4091f053ebe167eba2cf.tar.xz puppet-ef6a35a31b4ea311184d4091f053ebe167eba2cf.zip |
add backup for blog files
Diffstat (limited to 'modules/blog')
-rw-r--r-- | modules/blog/manifests/init.pp | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/modules/blog/manifests/init.pp b/modules/blog/manifests/init.pp index e42549cc..0c895bf4 100644 --- a/modules/blog/manifests/init.pp +++ b/modules/blog/manifests/init.pp @@ -80,4 +80,29 @@ class blog { require => [File["backup_blog-db"]], } } + class files_backup inherits base { + file { "/var/lib/blog/backup": + ensure => directory, + owner => root, + group => root, + mode => 644, + } + + file { "backup_blog-files": + path => "/usr/local/bin/backup_blog-files.sh", + ensure => present, + owner => root, + group => root, + mode => 755, + content => template("blog/backup_blog-files.sh") + } + + cron { "Backup files (blog)": + user => root, + hour => '23', + minute => '42', + command => "/usr/local/bin/backup_blog-files.sh", + require => [File["backup_blog-files"]], + } + } } |