aboutsummaryrefslogtreecommitdiffstats
path: root/modules/catdap
diff options
context:
space:
mode:
authorMichael Scherer <misc@mageia.org>2012-03-17 16:53:36 +0000
committerMichael Scherer <misc@mageia.org>2012-03-17 16:53:36 +0000
commit568be2adf123420070be66dbcba4c9e8b8ef40c8 (patch)
treeb8e08c4df977679f05d30ec56d7e86a68ca3feae /modules/catdap
parent50cb0e9b376e8efdbf0e581fba5da5b181097e3c (diff)
downloadpuppet-568be2adf123420070be66dbcba4c9e8b8ef40c8.tar
puppet-568be2adf123420070be66dbcba4c9e8b8ef40c8.tar.gz
puppet-568be2adf123420070be66dbcba4c9e8b8ef40c8.tar.bz2
puppet-568be2adf123420070be66dbcba4c9e8b8ef40c8.tar.xz
puppet-568be2adf123420070be66dbcba4c9e8b8ef40c8.zip
split snapshot.pp from init.pp to follow puppet convention of 1 module per file
Diffstat (limited to 'modules/catdap')
-rw-r--r--modules/catdap/manifests/init.pp25
-rw-r--r--modules/catdap/manifests/snapshot.pp20
2 files changed, 22 insertions, 23 deletions
diff --git a/modules/catdap/manifests/init.pp b/modules/catdap/manifests/init.pp
index 713b8b86..9cb4d22f 100644
--- a/modules/catdap/manifests/init.pp
+++ b/modules/catdap/manifests/init.pp
@@ -36,33 +36,12 @@ class catdap {
$ldap_password = extlookup('catdap_ldap','x')
- define catdap_snapshot($location, $svn_location) {
- file { "$location/catdap_local.yml":
- group => apache,
- mode => '0640',
- content => template('catdap/catdap_local.yml'),
- require => Subversion::Snapshot[$location],
- }
-
- subversion::snapshot { $location:
- source => $svn_location
- }
-
- apache::vhost_catalyst_app { $name:
- script => "$location/script/catdap_fastcgi.pl",
- location => $location,
- use_ssl => true,
- }
-
- apache::vhost_redirect_ssl { $name: }
- }
-
- catdap_snapshot { "identity.$::domain":
+ catdap::snapshot { "identity.$::domain":
location => '/var/www/identity',
svn_location => "$upstream_svn/branches/live"
}
- catdap_snapshot { "identity-trunk.$::domain":
+ catdap::snapshot { "identity-trunk.$::domain":
location => '/var/www/identity-trunk',
svn_location => "$upstream_svn/trunk"
}
diff --git a/modules/catdap/manifests/snapshot.pp b/modules/catdap/manifests/snapshot.pp
new file mode 100644
index 00000000..4dc7796f
--- /dev/null
+++ b/modules/catdap/manifests/snapshot.pp
@@ -0,0 +1,20 @@
+define catdap::snapshot($location, $svn_location) {
+ file { "$location/catdap_local.yml":
+ group => apache,
+ mode => '0640',
+ content => template('catdap/catdap_local.yml'),
+ require => Subversion::Snapshot[$location],
+ }
+
+ subversion::snapshot { $location:
+ source => $svn_location
+ }
+
+ apache::vhost_catalyst_app { $name:
+ script => "$location/script/catdap_fastcgi.pl",
+ location => $location,
+ use_ssl => true,
+ }
+
+ apache::vhost_redirect_ssl { $name: }
+}