aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--manifests/vserver.pp6
-rw-r--r--templates/flags.erb3
2 files changed, 9 insertions, 0 deletions
diff --git a/manifests/vserver.pp b/manifests/vserver.pp
index 63053a3..7a0db8e 100644
--- a/manifests/vserver.pp
+++ b/manifests/vserver.pp
@@ -148,6 +148,7 @@ define vs_create($in_domain, $context, $legacy = false, $distro = 'etch',
file { "/etc/vservers/${vs_name}/rlimits":
ensure => directory,
mode => 0755, owner => root, group => root,
+ require => File["/etc/vservers/${vs_name}"],
}
file { "/etc/vservers/${vs_name}/rlimits/rss.hard":
mode => 0644, owner => root, group => root,
@@ -159,6 +160,11 @@ define vs_create($in_domain, $context, $legacy = false, $distro = 'etch',
content => template("virtual/rss.soft.erb"),
require => File["/etc/vservers/${vs_name}/rlimits"],
}
+ file { "/etc/vservers/${vs_name}/flags":
+ mode => 0644, owner => root, group => root,
+ content => template("virtual/flags.erb"),
+ require => File["/etc/vservers/${vs_name}"],
+ }
}
}
}
diff --git a/templates/flags.erb b/templates/flags.erb
new file mode 100644
index 0000000..630fba7
--- /dev/null
+++ b/templates/flags.erb
@@ -0,0 +1,3 @@
+<% if memory_limit != false -%>
+VIRT_MEM
+<% end -%>