aboutsummaryrefslogtreecommitdiff
path: root/manifests/vserver.pp
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2013-01-23 11:34:08 -0200
committerSilvio Rhatto <rhatto@riseup.net>2013-01-23 11:34:08 -0200
commitc2e477d0a8667bc3a983105421d5c048faa31661 (patch)
treed403e5ca56e297591b7f0d738b33681cdb188791 /manifests/vserver.pp
parente87974d37018b7ab8cf422a0797644c20e84e0c6 (diff)
downloadpuppet-virtual-c2e477d0a8667bc3a983105421d5c048faa31661.tar.gz
puppet-virtual-c2e477d0a8667bc3a983105421d5c048faa31661.tar.bz2
Using class parameters for vserver::host
Diffstat (limited to 'manifests/vserver.pp')
-rw-r--r--manifests/vserver.pp12
1 files changed, 4 insertions, 8 deletions
diff --git a/manifests/vserver.pp b/manifests/vserver.pp
index 8f7437c..36a934a 100644
--- a/manifests/vserver.pp
+++ b/manifests/vserver.pp
@@ -4,7 +4,7 @@
module_dir{ "virtual/contexts": }
-class vserver::host {
+class vserver::host($vdirbase = "/var/lib/vservers") {
# make sure we have the ability to query for lsbdistcodename
include lsb
@@ -15,10 +15,6 @@ class vserver::host {
default => latest,
}
- case $vserver_vdirbase {
- '': { $vserver_vdirbase = "/var/lib/vservers" }
- }
-
package {
"util-vserver":
ensure => $utilvserver_version;
@@ -43,10 +39,10 @@ class vserver::host {
require => [ Package['util-vserver'], Package[debootstrap]];
"/etc/vservers/.defaults/vdirbase":
- ensure => $vserver_vdirbase,
- require => File[$vserver_vdirbase];
+ ensure => $vdirbase,
+ require => File[$vdirbase];
- "$vserver_vdirbase":
+ "$vdirbase":
ensure => directory,
mode => 000, owner => root, group => root;