On Wed, Sep 30, 2015 at 06:09:49PM +0000, Serge Hallyn wrote: > Quoting Christian Brauner (christianvanbrau...@gmail.com): > > While lxc-copy is under review let users benefit (reboot survival etc.) > > from the > > new lxc.ephemeral option already in lxc-start-ephemeral. This way we can > > remove > > the lxc.hook.post-stop script- > > > > Signed-off-by: Christian Brauner <christianvanbrau...@gmail.com> > > --- > > I'll leave this for Stéphane to review, as I'm especially unfamiliar > with the lxc-start-ephemeral code at this point.
Acked-by: Stéphane Graber <stgra...@ubuntu.com> > > > src/lxc/lxc-start-ephemeral.in | 10 +--------- > > 1 file changed, 1 insertion(+), 9 deletions(-) > > > > diff --git a/src/lxc/lxc-start-ephemeral.in b/src/lxc/lxc-start-ephemeral.in > > index d2c3904..3b3405c 100644 > > --- a/src/lxc/lxc-start-ephemeral.in > > +++ b/src/lxc/lxc-start-ephemeral.in > > @@ -306,16 +306,8 @@ touch $LXC_DIR/configured > > dest.set_config_item("lxc.hook.pre-mount", > > os.path.join(dest_path, "pre-mount")) > > > > -# Generate post-stop script > > if not args.keep_data: > > - with open(os.path.join(dest_path, "post-stop"), "w+") as fd: > > - os.fchmod(fd.fileno(), 0o755) > > - fd.write("""#!/bin/sh > > -[ -d "%s" ] && rm -Rf "%s" > > -""" % (dest_path, dest_path)) > > - > > - dest.set_config_item("lxc.hook.post-stop", > > - os.path.join(dest_path, "post-stop")) > > + dest.set_config_item("lxc.ephemeral", "1") > > > > dest.save_config() > > > > -- > > 2.6.0 > > > > _______________________________________________ > > lxc-devel mailing list > > lxc-devel@lists.linuxcontainers.org > > http://lists.linuxcontainers.org/listinfo/lxc-devel > _______________________________________________ > lxc-devel mailing list > lxc-devel@lists.linuxcontainers.org > 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 lxc-devel@lists.linuxcontainers.org http://lists.linuxcontainers.org/listinfo/lxc-devel