diff options
author | Michael Scherer <misc@mageia.org> | 2010-11-19 00:24:21 +0000 |
---|---|---|
committer | Michael Scherer <misc@mageia.org> | 2010-11-19 00:24:21 +0000 |
commit | f7254c82c2526397fd02e8df01508e9c8541a285 (patch) | |
tree | 64d855ea337cfa0d071c86c8510d792354931080 /modules/subversion | |
parent | b3451c938c27998eb81ecb360bce528de2e173d5 (diff) | |
download | puppet-f7254c82c2526397fd02e8df01508e9c8541a285.tar puppet-f7254c82c2526397fd02e8df01508e9c8541a285.tar.gz puppet-f7254c82c2526397fd02e8df01508e9c8541a285.tar.bz2 puppet-f7254c82c2526397fd02e8df01508e9c8541a285.tar.xz puppet-f7254c82c2526397fd02e8df01508e9c8541a285.zip |
implement the commit mail part
Diffstat (limited to 'modules/subversion')
-rw-r--r-- | modules/subversion/manifests/init.pp | 9 | ||||
-rw-r--r-- | modules/subversion/templates/hook_sendmail.pl | 13 |
2 files changed, 22 insertions, 0 deletions
diff --git a/modules/subversion/manifests/init.pp b/modules/subversion/manifests/init.pp index f1f6616e..3b7542e1 100644 --- a/modules/subversion/manifests/init.pp +++ b/modules/subversion/manifests/init.pp @@ -83,6 +83,15 @@ class subversion { mode => 755, } + if $commit_mail { + file { "$name/hooks/post-commit.d/send_mail": + ensure => present, + owner => root, + group => root, + mode => 755, + content => template("subversion/hook_sendmail.pl") + } + } } diff --git a/modules/subversion/templates/hook_sendmail.pl b/modules/subversion/templates/hook_sendmail.pl new file mode 100644 index 00000000..2444510b --- /dev/null +++ b/modules/subversion/templates/hook_sendmail.pl @@ -0,0 +1,13 @@ +#!/usr/bin/perl -MSVN::Notify::Config=$0 +--- #YAML:1.0 + +'': + PATH: "/usr/bin:/usr/local/bin" + handler: Alternative + alternative: HTML::ColorDiff + with-diff: 1 + to: +<% commit_mail.each do |mail| %> + - <%= mail %> +<% end %> + from: root@<%= domain %> |