On Wed, Dec 25, 2013 at 01:45:24PM +0900, KATOH Yasufumi wrote: > patch /etc/inittab in plamo container to shutdown when it receives SIGPWR. > (By default, plamo shutdowns to single user mode after 5minutes) > > Signed-off-by: KATOH Yasufumi <[email protected]>
Acked-by: Stéphane Graber <[email protected]> > --- > templates/lxc-plamo.in | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/templates/lxc-plamo.in b/templates/lxc-plamo.in > index b133da3..485f363 100644 > --- a/templates/lxc-plamo.in > +++ b/templates/lxc-plamo.in > @@ -178,6 +178,12 @@ configure_plamo() { > EOF > # /etc/inittab > cat <<- "EOF" | patch $rootfs/etc/inittab > + 32,33c32,33 > + < # What to do when power fails (shutdown to single user). > + < pf::powerfail:/sbin/shutdown -f +5 "THE POWER IS FAILING" > + --- > + > # What to do when power fails (shutdown). > + > pf::powerfail:/sbin/shutdown -h +0 "THE POWER IS FAILING" > 47a48 > > 1:1235:respawn:/sbin/agetty 38400 console > 52,53d52 > -- > 1.8.4.4 > > _______________________________________________ > lxc-devel mailing list > [email protected] > http://lists.linuxcontainers.org/listinfo/lxc-devel -- Stéphane Graber Ubuntu developer http://www.ubuntu.com
signature.asc
Description: Digital signature
_______________________________________________ lxc-devel mailing list [email protected] http://lists.linuxcontainers.org/listinfo/lxc-devel
