aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--manifests/vserver.pp20
1 files changed, 19 insertions, 1 deletions
diff --git a/manifests/vserver.pp b/manifests/vserver.pp
index 26f4414..ec9885a 100644
--- a/manifests/vserver.pp
+++ b/manifests/vserver.pp
@@ -157,18 +157,36 @@ define vs_create($in_domain, $context, $legacy = false, $distro = 'etch',
}
case $memory_limit {
- false: { }
+ false: {
+ file { "/etc/vservers/${vs_name}/rlimits/rss.hard":
+ mode => 0644, owner => root, group => root,
+ ensure => absent,
+ }
+
+ file { "/etc/vservers/${vs_name}/rlimits/rss.soft":
+ mode => 0644, owner => root, group => root,
+ ensure => absent,
+ }
+
+ vs_cflags { "${vs_name}-virt_mem":
+ vserver => $vs_name,
+ flag => "virt_mem",
+ ensure => absent,
+ }
+ }
default: {
file { "/etc/vservers/${vs_name}/rlimits":
ensure => directory,
mode => 0755, owner => root, group => root,
require => Exec["vs_create_${vs_name}"],
}
+
file { "/etc/vservers/${vs_name}/rlimits/rss.hard":
mode => 0644, owner => root, group => root,
content => template("virtual/rss.hard.erb"),
require => File["/etc/vservers/${vs_name}/rlimits"],
}
+
file { "/etc/vservers/${vs_name}/rlimits/rss.soft":
mode => 0644, owner => root, group => root,
content => template("virtual/rss.soft.erb"),