Created
January 16, 2014 19:24
-
-
Save caglar10ur/8461614 to your computer and use it in GitHub Desktop.
/etc/init/cgmanager.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
description "cgroup management daemon" | |
author "Serge Hallyn <serge.hallyn@ubuntu.com>" | |
respawn | |
# in trusty /sys/fs/cgroup will be mounted for us. | |
# prior to saucy, we would need to start on mounted | |
# MOUNTPOINT=/sys, and mount /sys/fs/cgroup ourselves | |
start on mounted MOUNTPOINT=/sys/fs/cgroup | |
script | |
test -x /sbin/cgmanager || { stop; exit 0; } | |
# check whether we should start a cgproxy or a cgmanager | |
tostart=/sbin/cgproxy | |
dbus-send --print-reply --address=unix:path=/sys/fs/cgroup/cgmanager/sock --type=method_call /org/linuxcontainers/cgmanager org.linuxcontainers.cgmanager0_0.ping int32:0 > /dev/null 2>&1 || tostart=/sbin/cgmanager | |
exec $tostart | |
end script | |
post-stop script | |
rm /sys/fs/cgroup/cgmanager/sock || true | |
end script |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment