aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2013-01-19 16:06:17 -0200
committerSilvio Rhatto <rhatto@riseup.net>2013-01-19 16:06:17 -0200
commitf1d3d0c1f56967b61410d688bdb77bd6aa5ae1da (patch)
treef6fb51e7a8937db3474397f4a43ad42bb5f11fc2
parent589373257c1d7fd8e864bbdad2c2085ea91f768c (diff)
downloadpuppet-pmwiki-f1d3d0c1f56967b61410d688bdb77bd6aa5ae1da.tar.gz
puppet-pmwiki-f1d3d0c1f56967b61410d688bdb77bd6aa5ae1da.tar.bz2
Upgrading for 2.7 compatibility --config
-rw-r--r--manifests/init.pp8
-rw-r--r--templates/pmwiki.sh.erb2
2 files changed, 4 insertions, 6 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index eec5e96..a402e9e 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -1,8 +1,6 @@
-class pmwiki {
-
- case $apache_www_folder {
- '': { fail("you need to define \$apache_www_folder for pmwiki module") }
- }
+class pmwiki(
+ $www_folder = ${apache_www_folder}
+) {
file { "/usr/local/sbin/pmwiki":
ensure => present,
diff --git a/templates/pmwiki.sh.erb b/templates/pmwiki.sh.erb
index 4b1e9dc..204916e 100644
--- a/templates/pmwiki.sh.erb
+++ b/templates/pmwiki.sh.erb
@@ -3,7 +3,7 @@
# pmwiki management script.
#
-BASE="<%= apache_www_folder %>"
+BASE="<%= scope.lookupvar('pmwiki::www_folder') %>"
# Check for existing installations
function pmwiki_check_existing {