[lxc-devel] lxc-clone rewrite

Stéphane Graber stgraber at ubuntu.com
Thu Aug 27 19:41:03 UTC 2015


On Sun, Aug 16, 2015 at 04:46:31PM +0000, Serge Hallyn wrote:
> Quoting Christian Brauner (christianvanbrauner at gmail.com):
> > Integrating lxc-clone with the standard lxc parser is not possible unless it is
> > allowed to change command line options. lxc-clone uses -n, -P and -o in a way
> > that is inconsistent with the standard lxc common options defined in
> > LXC_COMMON_OPTIONS in arguments.h and the parser in arguments.c. Since we do not
> > want to break expectations of existing users that rely on lxc-clone I thought it
> > might be a good idea to reimplement lxc-clone as lxc-copy. This way we can
> > retain lxc-clone as a working executable but have it print out a "will soon be
> > deprecated. Please switch to lxc-copy"-type message similar to what e.g. Docker
> > does. The main arguments for reimplementing lxc-clone for is the tighter
> > integration with the rest of the lxc-executables, using the standard parser and
> > most of all the standard lxc-logging feature which we get by integrating it with
> > the standard parser. I provided a branch on github which implements this idea
> > (manpages and all included).
> > 
> >         git clone https://github.com/brauner/lxc.git
> >         git checkout copy
> > 
> > I'd be happy to hear whether you think this is a good idea or if you would like
> > to just keep the old lxc-clone.
> 
> Hey,
> 
> I'll leave this to Stéphane, as he's pretty keen on leaving the # commands
> low.  As you say we might eventually be able to deprecate lxc-clone, and
> lxc-copy might eventually be a nice hook for migration.

That'd be fine with me I think, bonus point if we can somehow merge
lxc-start-ephemeral in there and kill two birds with one stone
(lxc-clone & lxc-start-ephemeral).

The timeline for this would be having lxc-copy in 1.2 with both
lxc-clone and lxc-start-ephemeral doing arg swapping + re-exec tricks
with a warning that they'll go away for good in 2.0.

How does that sound?

-- 
Stéphane Graber
Ubuntu developer
http://www.ubuntu.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20150827/c59d167c/attachment.sig>


More information about the lxc-devel mailing list