[lxc-devel] [GIT] lxc branch, master, updated. 64e9369c8f82ef9256388726b77b20f042a54809
Daniel Lezcano
git at users.sourceforge.net
Mon Feb 18 08:17:28 UTC 2013
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "lxc".
The branch, master has been updated
via 64e9369c8f82ef9256388726b77b20f042a54809 (commit)
via 89db34e743c880e11438921b2faea868e8c5bd42 (commit)
via 83c98d825e4e644b18276dde5deaa555ee36b629 (commit)
via 13f5be6276100761eaeddd77b7b55fbec6b0c9ab (commit)
via edb09f8d1bb822c4f23d745ae8117bf084e1d12c (commit)
via afeecbba0359d2b4404cdf896e6b6d0b5a8443b0 (commit)
via 35fef4e6c96b132c317994beb77817949c8c1808 (commit)
via 4019712d198a7d50b08b326ade17f5ff1666efbb (commit)
via 810567bbbe283c547e4ac837545d1e592916df26 (commit)
via 11cddd70eb8c285287b73562ba4208d74e1b9fde (commit)
via 233c1292c3bc5080da28b3e1844c33e25c04d034 (commit)
via 113c39bfb8ed8307c2ea0ab4cd4f9035a7880bd5 (commit)
via 4852d800d11740225072579e8bd8c4b56df581ee (commit)
via 2a59a68183e55e38beedb6442938e31eb7d4749c (commit)
via 839af5b39bbdc53c0205389145fec108b39811ca (commit)
via bb9702b539188bcc0c37f351633b087d1c22d2a6 (commit)
via c9f8b9859d59c25f7e07885166079a81b27fc0cd (commit)
via f080ffd7d656fbd9505a8e8eb52a05d61355c677 (commit)
via 68c152ef7a2fe18f71cb73a4800501a7c008bf46 (commit)
via 5e1e7aaf1e244405b813c0f9e20db2fc9e7f4d10 (commit)
via 1ff8a4606d223b79545573d517dc80f9c2f70fd6 (commit)
via ce95113287f87460dd557d818280639fc2a31e19 (commit)
via e6cde7418c4e697876f0041b888766ab4732812b (commit)
via b02bbfacd76a7653a2f985bbefb580a44cbeb562 (commit)
via b8e0503a1d1dbf3a508bf6f34521606ba231b1fe (commit)
via 74476cf144523530022d76cef3a558b0662b592f (commit)
via 81b2d972412748f7644116b2c7da65e2a9135feb (commit)
via 169bf5e07ed044a11fe6f5dd683615bee001ee36 (commit)
via 2b0e17e48f4f55ddfcde74d1f00932837fa2cfda (commit)
via 20087962333e574603ec65789624dc35a6da43bb (commit)
via b3ef6e1678bc4e7a836b1d4a91daa57d5ecb17b8 (commit)
via c94e60d16bfcda262ac907bf9667abdc46c07fa8 (commit)
via f6d3e3e47069b2bfc15de7cc81ccb0200aa2c341 (commit)
via 544a48a0bdad50b601ab2d186aa78e71a47f92cd (commit)
via c4ea60dff6ac1dfd4dcce11ffd7b3007bb108122 (commit)
via 8538f3880636497c3b1345cb559dd042f374bdc2 (commit)
via f7bee6c6f30c92252f07a5468f9c89c309a740c2 (commit)
via 9ea87d5dedf7b56eb7eeb20b0da2252d9a1087b1 (commit)
via f15b77ca275852cf6d6a34e2e98b29737ed32cb1 (commit)
via 740ee8c7754f68bc6a467bd298c9589647f4d92b (commit)
via e316c085399d1cb487ae302e05fbf241df4eb615 (commit)
via 565c2d76a30d29ecce76ca595cf79dd1e528399e (commit)
via 9be380b07b1e05505469f213cf5a4612abe2dd53 (commit)
via a45bbcedb2ee8e97e81e40c449050beed74295b9 (commit)
via 59ec0a36c7b5e0c60eab1a626d2af24a96de5c5c (commit)
via 148315348760faf4ad822ded7c416d2de8050937 (commit)
via f298ee50b8cfa46f20138f95ca916ec4b54c9a45 (commit)
via cbec003096b98bd62e46bae9f3a2fce90b06e650 (commit)
via ed34a67d010fd353812bceb70940bcb6c35a51a3 (commit)
via e9f2c74c3da6823c2530a6078545f785d192076c (commit)
via 7af3759fea144f73ddf1c2c7c35d468a2b8ba133 (commit)
via c1dc38c2e805cc82489d442185ad57d8334bde76 (commit)
via fd5c4f905861964cb473cf3df3336447a9365962 (commit)
via 5c0f1b3b2fb0653a4463e005bfc39b9b6d2934fd (commit)
via 72f919c42a7b327b92b03206662ba3accad31bae (commit)
via edaf8b1bf1ca57202af0ffb53dcd665b01695888 (commit)
via c4b790845d76edd2ed2f7ed8973dc194be38123a (commit)
via 956edc54969dc3e3653ea3e410522eb1def22588 (commit)
via da9dd0f14d91713d48465b7cbf8bc05922d2415f (commit)
via ffbf58150c7a12ea2a133507f5f400ff3c839c12 (commit)
via 2d76d1d7e5fc15693e086ca46dc06ef0fd74806e (commit)
via 6ff05e18a3fcda14df31d833612bddee4bb09534 (commit)
via 495d2046f6fd0143e368f59746c6d24cef8ad87f (commit)
via e827ff7e2f3c1c18e5823312482f0f45e03cb6a8 (commit)
via 1f1665e6caa1835a2c5c5e369d69b8fa225effe3 (commit)
via 9818cae412c5446ec9ec86127c97d7e3822bd459 (commit)
via 8173e600ef80d3f3685a6f1f933ab92f09a160c9 (commit)
via d2717c14d8bb06967a6817d7909a2ee87b523002 (commit)
via 20d2e91bd3495f4368396cd13a0507d716703286 (commit)
via 1ba0013f21e1953ae4a59cdf61562fbe843077e9 (commit)
via 7c11d57a22668c838ecec57372a3534b5c956400 (commit)
via 8aa4885c224acf396a9413a272b97928f7345ede (commit)
via a6168a17ee9d7fb3f3eaec61c0db724bf877afdc (commit)
via 3a32201c5a442c2732861aeee1a5f70909718b90 (commit)
via c5b908a262d30dfc6a5969b22a7e25fe167447fd (commit)
via d378aebe3da108502ea5ff8fc134491214135057 (commit)
via 768487891f16c539954f871ef2e36ebd5556ccb2 (commit)
via 29e18143a07ffab7e85cb8db4dc39d394f0c6ea0 (commit)
via bd9a66b20c33dda261e794b4aa19c653cb7a98c8 (commit)
via bc2333ebeca7a2443c7c4a004dc6dd25e9aba15c (commit)
via d27b0806cdd7f4bf45a83b9c3dc97320ac18f492 (commit)
via e35cb41b8c187980825c9be2c628a137ffeeee6b (commit)
via 596a818d4b8b55586d36af518b745cd96b24c67a (commit)
via 4199da3061d02e9b5087faa16dd875d4bfeb3989 (commit)
via 670c6ab8caac48ce5cf043796dd8908114b7f607 (commit)
via 2b49de9a3ff182c208148d780f6b26cf8cdd09d8 (commit)
via e5846a6f89db72bdbf3d651e5faf232045d17af8 (commit)
via b1aa0624bae5a81d6f6bbc2653a388d148cffef8 (commit)
via 8410c48507cdd72fb13f1d4476f63f0d5c75e359 (commit)
via b5dec5f30bdf6137789bd19eee5393ed8b60840e (commit)
via 600faead3804e7f507e18bdb41588964b0fc611f (commit)
via 4415d5163c17d462def86566c33910772237e0ce (commit)
via 7265dc4344d5d0555e9a88467eaee392594e3171 (commit)
via 32e869018640e0d898031de20514e0ffca79baa9 (commit)
via f358385a7cf0ec74925d7f26b8a9dab1225dc2b6 (commit)
via f3849d01d8f31785bf933ffcf91a419c4ff2257d (commit)
via c44fc03789973cab0d689617e3c2f7ec02fd29f7 (commit)
via 4785915a51890379393e5a87b6c987d7444d4abe (commit)
via 2f0e69084ed061dd00e7e1123514800aa7b851b9 (commit)
via 11bdaa7475f54571537aaf2ba05f78068fac3099 (commit)
via 2a9a0a08077d88ee1d70ca46ca122216f3d1c89a (commit)
via 5270bf4b088328d6188211eb02909de4a1a04b68 (commit)
via 859a6da0fac5d214230f8a52777277b5147532fb (commit)
via 964fe051e9dc21be6c52ccf5b9ff47a8aea396fc (commit)
via cc28d0b0a66bd956645dc7b8fc85b917711f2472 (commit)
via 963aef6f7f127c43cded0fe628a1b00fe9afb16e (commit)
from 56655134e462ceaf86b51838e4e825c2f3964922 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 64e9369c8f82ef9256388726b77b20f042a54809
Author: Daniel Lezcano <daniel.lezcano at free.fr>
Date: Mon Feb 18 08:48:32 2013 +0100
version 0.9.0-alpha2
Signed-off-by: Daniel Lezcano <daniel.lezcano at free.fr>
commit 89db34e743c880e11438921b2faea868e8c5bd42
Merge: 5665513 83c98d8
Author: Daniel Lezcano <daniel.lezcano at free.fr>
Date: Wed Feb 13 09:50:27 2013 +0100
Merge git://github.com/lxc/lxc
Signed-off-by: Daniel Lezcano <daniel.lezcano at free.fr>
commit 83c98d825e4e644b18276dde5deaa555ee36b629
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Mon Feb 11 17:31:39 2013 -0500
Update Lua API
Add [gs]et_config_path from API to Lua binding. Add additional optional
parameter to container_new(). Add tests for these new Lua API bindings.
Commit 2a59a681 changed the meaning of lxc_path_get() in the binding,
causing lua script breakage. Reinstate original behavior of
lxc_path_get() and rename it to lxc_default_config_path_get() to make
its intent clearer.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 13f5be6276100761eaeddd77b7b55fbec6b0c9ab
Author: Serge Hallyn <serge.hallyn at ubuntu.com>
Date: Mon Feb 11 14:43:41 2013 -0600
pass lxcpath to lxc_command
The previous lxcpath patches added support for a custom LXCPATH set
through a system-wide configuration file.
This was also exposed through the C api, so that a custom lxcpath could
be set at the container object instanciation time, or set at runtime.
However the command sock filename was always located under the global
lxcpath, which could be confusing, and would be a problem for users
with insufficient perms to the system-wide lxc path (i.e. if setting
lxcpath to $HOME/lxcbase). This patch changes that by passing the
lxcpath to all callers of lxc_command().
It remains to add an lxcpath command line argument to most of the
command line tools (which are not using the C api) - lxc-start,
lxc-info, lxc-stop, etc.
At this point it becomes tempting to do something like
c = lxc.Container("r1", "/var/lib/lxc")
c2 = lxc.Container("r1", "$HOME/lxcbase")
However, that's problematic - those two will use the same directory
names for cgroup directories.
What would be the best way to handle this? One way (which I kind
of like) is to give up on naming the cgroups after the container.
use mkstemp for the cgroup name, let lxc keep track of the cgroup
name based on the command socket, and make users use lxc-cgroup to get
and change settings.
Other ideas?
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit edb09f8d1bb822c4f23d745ae8117bf084e1d12c
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Mon Feb 11 13:45:20 2013 -0500
python-lxc: Update for new calls
Add the two new calls to the API and add the new container_path
parameter to the constructor (optional).
This also extends list_containers to support the config_path parameter.
At this point none of the actual tools are changed to make use of those
as we'll probably want to make sure all the tools get the extra option
at once.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Tested-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit afeecbba0359d2b4404cdf896e6b6d0b5a8443b0
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Fri Feb 8 16:06:32 2013 -0600
lxc api: fix some config_path oddities
1. When calling c->set_config_path(), update configfile. I.e. if we
are setting the config_path to /var/lib/lxc, then the configfile should
be changed to /var/lib/lxc/$container/config
2. Add an optional configpath argument to lxc_container_new. If NULL,
then the default will be used (as before). If set, then the passed-in
path will be used. This way you can do
c1 = lxc.Container("r1", "/var/lib/lxc");
c2 = lxc.Container("r2", "/home/user/lxcbase");
(Note I did *not* implement the python or lua binding to pass that
argument along)
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 35fef4e6c96b132c317994beb77817949c8c1808
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Sat Feb 9 14:52:12 2013 -0500
lxc-create: Improve the layout of the config
This simply adds an extra blank line between the original lxc config
and the template generated options.
In typical use cases, this means that we'll now get the header, then
a blank line, then default.conf content, then a blank line and finally
the template generated config.
The wording of the header is also changed slightly so that it fits in
the usual 80 columns.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 4019712d198a7d50b08b326ade17f5ff1666efbb
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Fri Feb 8 18:49:52 2013 -0500
Add missing manpages
This introduces manpages for:
- lxc-checkconfig
- lxc-device
- lxc-info
- lxc-netstat
- lxc-shutdown (wasn't in Makefile)
- lxc-start-ephemeral
- lxc-version
This commit also sorts configure.ac and Makefile.am.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 810567bbbe283c547e4ac837545d1e592916df26
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Fri Feb 8 17:32:32 2013 -0600
add lxc-unshare man page, and make 'lxc-unshare -h' work.
Also fix some tabs-as-spaces in lxc_unshare.c itself.
lxc-unshare: run usage() on '-h'
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 11cddd70eb8c285287b73562ba4208d74e1b9fde
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Fri Feb 8 16:58:01 2013 -0600
Add man page for lxc-clone
And doing so pointed out a bug in lxc-clone itself - it claims
default fssize is 2G. It's not.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 233c1292c3bc5080da28b3e1844c33e25c04d034
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Fri Feb 8 16:01:02 2013 -0500
lxc.functions isn't a shell script
lxc.functions.in is meant to be sourced, not to be called as a script.
So as it's not executable and not meant to be, it shouldn't have
a /bin/sh shebang.
This fixes an error reported by lintian.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 113c39bfb8ed8307c2ea0ab4cd4f9035a7880bd5
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Fri Feb 8 11:07:53 2013 -0500
Drop lxc-setcap and lxc-setuid
As discussed earlier this week, lxc-setcap and lxc-setuid have been
in pretty bad shape lately. Most if not all distros recommend against
using them or don't ship them at all.
With the ongoing work to get user namespaces working in upstream LXC,
we think it's best to drop those two now as we prepare to land proper
setuid helpers to deal with user namespaces.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 4852d800d11740225072579e8bd8c4b56df581ee
Author: Alexander Vladimirov <alexander.idkfa.vladimirov at gmail.com>
Date: Thu Feb 7 16:13:56 2013 +0800
Update lxc-archlinux template.
Add mknod to lxc.cap.drop since udev is conditioned on CAP_MKNOD capability.
Update base package list.
Signed-off-by: Alexander Vladimirov <alexander.idkfa.vladimirov at gmail.com>
Acked-by: Serge Hallyn <serge.hallyn at ubuntu.com>
commit 2a59a68183e55e38beedb6442938e31eb7d4749c
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Wed Feb 6 15:11:19 2013 -0600
Switch from use of LXCPATH to a configurable default_lxc_path
Here is a patch to introduce a configurable system-wide
lxcpath. It seems to work with lxc-create, lxc-start,
and basic python3 lxc usage through the api.
For shell functions, a new /usr/share/lxc/lxc.functions is
introduced which sets some of the basic global variables,
including evaluating the right place for lxc_path.
I have not converted any of the other python code, as I was
not sure where we should keep the common functions (i.e.
for now just default_lxc_path()).
configure.ac: add an option for setting the global config file name.
utils: add a default_lxc_path() function
Use default_lxc_path in .c files
define get_lxc_path() and set_lxc_path() in C api
use get_lxc_path() in lua api
create sh helper for getting default path from config file
fix up scripts to use lxc.functions
Changelog:
feb6:
fix lxc_path in lxc.functions
utils.c: as Dwight pointed out, don't close a NULL fin.
utils.c: fix the parsing of lxcpath line
lxc-start: print which rcfile we are using
commands.c: As Dwight alluded to, the sockname handling was just
ridiculous. Clean that up.
use Dwight's recommendation for lxc.functions path: $datadir/lxc
make lxccontainer->get_config_path() return const char *
Per Dwight's suggestion, much nicer than returning strdup.
feb6 (v2):
lxccontainer: set c->config_path before using it.
convert legacy lxc-ls
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 839af5b39bbdc53c0205389145fec108b39811ca
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Mon Feb 4 18:51:47 2013 -0500
oracle template: improve compatibility with old ol4, 5
Reported-by: Alvaro Miranda <mirandaa at redrock.net.nz>
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit bb9702b539188bcc0c37f351633b087d1c22d2a6
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Mon Feb 4 16:53:25 2013 -0500
Rename /etc/lxc/lxc.conf to /etc/lxc/default.conf.
This will soon be followed by the introduction of a "real" system wide
/etc/lxc/lxc.conf storing global LXC settings.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit c9f8b9859d59c25f7e07885166079a81b27fc0cd
Author: Tomohiro Matsuyama <tomo at cx4a.org>
Date: Sun Jan 27 20:54:17 2013 +0900
Add missing option -t/--fstype.
Signed-off-by: Tomohiro Matsuyama <tomo at cx4a.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit f080ffd7d656fbd9505a8e8eb52a05d61355c677
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Thu Jan 24 11:42:22 2013 -0500
add lua binding for the lxc API
The lua binding is based closely on the python binding. Also included are
a test program for excercising the binding, and an lxc-top utility for
showing statistics on running containers.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 68c152ef7a2fe18f71cb73a4800501a7c008bf46
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Mon Jan 28 16:57:24 2013 -0600
setup_mount_entries: ignore mount failure if 'optional'
If 'optional' is in the mount options, then avoid failure in
mount().
Experiments suggest we could just do this checking data at
mount_entry(), but that feels less proper than using
hasmntopt() against the mntent.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 5e1e7aaf1e244405b813c0f9e20db2fc9e7f4d10
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Thu Jan 24 12:04:54 2013 -0600
use a default per-container logfile
Until now, if a lxc-* (i.e. lxc-start) command did not specify a logfile
(with -o logfile), the default was effectively 'none'. With this patch,
the default becomes a per-container log file.
If a container config file specifies 'lxc.logfile', that will override
the default. If a '-o logfile' argument is specifed at lxc-start,
then that will override both the default and the configuration file
entry. Finally, '-o none' can be used to avoid having a logfile at
all (in other words, the previous default), and that will override
a lxc.logfile entry in the container configuration file.
If the user does not have rights to open the default, then 'none' will
be used. However, in that case an error will show up on console. (We
can work on removing that if it annoys people, but I think it is
helpful, at least while we're still ironing this set out) If the user
or container configuration file specified a logfile, and the user does
not have rights to open the default, then the action will fail.
One slight "mis-behavior" which I have not fixed (and may not fix) is
that if a lxc.logfile is specified, the default logfile will still
get created before we read the configuration file to find out there
is a lxc.logfile entry.
changelog: Jan 24:
add --enable-configpath-log configure option
When we log to /var/lib/lxc/$container/$container.log, several things
need to be done differently than when we log into /var/log/lxc (for
instance). So give it a configure option so we know what to do
When the user specifies a logfile, we bail if we can't open it. But
when opening the default logfile, the user may not have rights to
open it, so in that case ignore it and continue as if using 'none'.
When using /var/lib/lxc/$c/$c.log, we use $LOGPATH/$name/$name.log.
Otherwise, we use $LOGPATH/$name.log.
When using /var/lib/lxc/$c/$c.log, don't try to create the log path
/var/lib/lxc/$c. It can only not exist if the container doesn't
exist. We don't want to create the directory in that case. When
using /var/log/lxc, then we do want to create the path if it does
not exist.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 1ff8a4606d223b79545573d517dc80f9c2f70fd6
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Fri Jan 25 17:41:34 2013 -0500
oracle template: fix sudo lxc-create on ubuntu
rpm on ubuntu puts the rpm db under $HOME, which wont be /root if
sudo is used
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit ce95113287f87460dd557d818280639fc2a31e19
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Wed Jan 23 12:59:21 2013 -0500
include python files in make dist and rpm
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit e6cde7418c4e697876f0041b888766ab4732812b
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Wed Jan 23 17:20:11 2013 -0500
Revert "use a default per-container logfile"
The logfile changes broke lxc-info and possibly more command line
tools. Revert for now until we get those issues addressed.
This reverts commit 74476cf144523530022d76cef3a558b0662b592f.
commit b02bbfacd76a7653a2f985bbefb580a44cbeb562
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Wed Jan 23 17:19:40 2013 -0500
Revert "use a default per-container logfile"
The logfile changes broke lxc-info and possibly more command line
tools. Revert for now until we get those issues addressed.
This reverts commit b8e0503a1d1dbf3a508bf6f34521606ba231b1fe.
commit b8e0503a1d1dbf3a508bf6f34521606ba231b1fe
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Wed Jan 16 16:37:46 2013 -0600
use a default per-container logfile
log_open: make sure the parent directory for logfiles
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 74476cf144523530022d76cef3a558b0662b592f
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Tue Jan 15 23:02:20 2013 -0600
use a default per-container logfile
[ Thanks to Stéphane and Dwight for the feedback on the previous patch ]
Until now, if a lxc-* (i.e. lxc-start) command did not specify a logfile
(with -o logfile), the default was effectively 'none'. With this patch,
the default becomes $LOGPATH/<container>/<container>.log. LOGPATH is
specified at configure time with '--with-log-path='. If unspecified, it
is $LXCPATH, so that logs for container r2 will show up at
/var/lib/lxc/r2/r2/log. LOGPATH must exist, while lxc will make sure to
create $LOGPATH/<name>. As another example, Ubuntu will likely specify
--with-log-path=/var/log/lxc (and place /var/log/lxc into
debian/lxc.dirs), placing r2's logs in /var/log/lxc/r2/r2.log.
If a container config file specifies 'lxc.logfile', that will override
the default. If a '-o logfile' argument is specifed at lxc-start,
then that will override both the default and the configuration file
entry. Finally, '-o none' can be used to avoid having a logfile at
all (in other words, the previous default), and that will override
a lxc.logfile entry in the container configuration file.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 81b2d972412748f7644116b2c7da65e2a9135feb
Author: Matthias Brugger <matthias.bgg at gmail.com>
Date: Tue Jan 22 19:00:41 2013 +0100
lxc-setcap.in: Set path to lxc-init
In lxc-setcap the path to lxc-init wasn't set right, so that
a call to the script failed with an error. This patch sets
the path to the right directory.
Signed-off-by: Matthias Brugger <matthias.bgg at gmail.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 169bf5e07ed044a11fe6f5dd683615bee001ee36
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Tue Jan 22 15:59:44 2013 -0500
use which instead of type
This is for consistency with the rest of lxc, and also because type checks for
shell builtins, a behavior that we do not want in these cases. Ensure stderr
for which is redirected to /dev/null also.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 2b0e17e48f4f55ddfcde74d1f00932837fa2cfda
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Thu Jan 17 09:53:33 2013 -0600
don't leak the rootfs.pin fd into the container
Only the container parent needs to keep that fd open. Close it
as soon as the container's first task is spawned. Else it can
show up in /proc/$$/fd in the container.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 20087962333e574603ec65789624dc35a6da43bb
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Tue Jan 15 12:44:50 2013 -0500
conf.c: Cast st_uid and st_gid to int
In eglibc st_uid and st_gid are defined as unsigned integers, in bionic those
are defined as unsigned long (which is inconsistent with the kernel's
defintion that's uint_32).
To workaround this problem, simply cast those two to int.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit b3ef6e1678bc4e7a836b1d4a91daa57d5ecb17b8
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Tue Jan 15 12:20:51 2013 -0500
lxc-oracle.in: Clear trailing whitespaces
A quick scan through the code showed that lxc-oracle.in is the only
file in the branch containing trailing whitespaces, this clears them.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
commit c94e60d16bfcda262ac907bf9667abdc46c07fa8
Author: Purcareata Bogdan-B43198 <B43198 at freescale.com>
Date: Mon Jan 14 14:21:41 2013 +0000
Add Dropbear SSH support for lxc-busybox template
Dropbear implements lightweight SSH2 server and client functionality and
is likely to be included in embedded Linux distros.
Signed-off-by: Purcareata Bogdan <B43198 at freescale.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit f6d3e3e47069b2bfc15de7cc81ccb0200aa2c341
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Mon Jan 14 18:03:06 2013 -0600
Implement userid mappings (enable user namespaces)
The 3.8 kernel now supporst uid mappings, so I believe it's appropriate
to proceed with this patchset.
The container config supports new entries of the form:
lxc.id_map = U 100000 0 10000
lxc.id_map = G 100000 0 10000
meaning map 'virtual' uids (in the container) 0-10000 to uids
100000-110000 on the host, and same for gids. So long as there are
mappings specified in the container config, then CONFIG_NEWUSER will
be used when the container is cloned. This means that container
setup is no longer done with root privilege on the host, only root
privilege in the container. Therefore cgroup setup is moved from the
init task to the monitor task.
To use this patchset, you currently need to either use the raring
kernel at ppa:serge-hallyn/usern-natty, or build your own kernel
from either git://kernel.ubuntu.com/serge/quantal-userns.git.
(Alternatively you can use Eric's tree at the latest userns-always-map-*
branch at
git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace.git
but you will likely want to at least enable tmpfs mounts in user namespaces)
You also need to chown the files in the container rootfs into the
mapped range. There is a utility at
https://code.launchpad.net/~serge-hallyn/+junk/nsexec to do this.
uidmapshift does the chowning, while the container-userns-convert
script nicely wraps that program. So I simply
sudo lxc-create -t ubuntu -n r1
sudo container-userns-convert r1 200000
will create a container which is shifted so uid 0 in the container
is uid 200000 on the host.
TODO: when doing setuid(0), need to only do that if 0 is one of the
ids we map to. Similarly, when dropping capabilities, need to only
not do that if 0 is one of the ids we map to. However, the question
of what to do for 'weird' containers in private user namespaces is
one I'm punting for later.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 544a48a0bdad50b601ab2d186aa78e71a47f92cd
Author: Serge Hallyn <serge.hallyn at ubuntu.com>
Date: Mon Jan 14 23:32:44 2013 +0000
setup cgroups from parent
This is a first step to enabling user namespaces. When starting a
container in a new user namespace, the child will not have the
rights to write to the cgroup fs. (We can give it that right, but
don't always want to have to).
At the parent, we don't want to setup_cgroups() before the child
has set itself up. But we also don't want to wait until it has
started running it's init, since that is racy.
Therefore introduce a new sync point. The child will let the
parent know when it is ready to be confined, and wait for the
parent to respond that it has done so. Then the child will finish
constraining itself with LSM and seccomp and execute init.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit c4ea60dff6ac1dfd4dcce11ffd7b3007bb108122
Author: Serge Hallyn <serge.hallyn at ubuntu.com>
Date: Mon Jan 14 23:32:43 2013 +0000
clean up syncs
Always unblock parent when child setup fails, rather than just
exiting.
Also remove a duplicate call to setup_cgroup(). We'll want it
close to there for userns, but not right there - that's too late,
and could happen after container init has done something bad
without cgroup restrictions.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 8538f3880636497c3b1345cb559dd042f374bdc2
Author: Christian Seiler <christian at iwakd.de>
Date: Tue Jan 15 14:44:25 2013 +0100
Multiple IP addresses: add them in the correct order
Make sure that when configuring containers that have interfaces containing
multiple IP addresses they are added in the order of the configuration file
(i.e. the first being the primary one) and not the reverse order.
Signed-off-by: Christian Seiler <christian at iwakd.de>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit f7bee6c6f30c92252f07a5468f9c89c309a740c2
Author: Michael H. Warfield <mhw at WittsEnd.com>
Date: Mon Jan 14 11:59:36 2013 -0500
MAKEDEV call, add autodev hooks, add environment variables for hook scripts.
Ok... Here's the patch again. Since Serge is removing the loglevel
structure member, this patch no longer references that element.
From the original description:
1) Removes run_makedev() and the call to it from conf.c per discussion.
2) Adds an lxc.hook.autodev hook.
Note: This hook is very close (one routine level abstracted) from where
the run_makedev was called. Anyone really rrreeeaaalllyyy needing
MAKEDEV can add it in with a small shim script to do whatever they want
under whatever distro they're using, so no functionality is lost there.
3) Added a number of environment variables for all the hook scripts to
reference to assist in execution. Things like LXC_ROOTFS_MOUNT could be
very useful but others were added as well. Room for more if anyone has
an itch. All in one spot in lxc_start.c.
4) clearenv and putenv( "container=lxc" ) calls were moved to just after
the "start" hook in the container just prior to actually firing up the
container so we could use environment variables prior to that and have
them flushed them before firing up init. Nice side effect is that you
can define environment variables and then call lxc-start and have them
show up in those hooks scripts.
5) I actually DID update the man page for lxc.conf! I guess I lied when
I said I wouldn't get that done.
[... and ...]
I added the rcfile to the lxc_conf structure as suggested and moved the
setenv bundle from lxc-start.c over to start.c just prior to calling
run_lxc_hooks for the pre-start hook.
Signed-off-by: Michael H. Warfield <mhw at WittsEnd.com>
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
commit 9ea87d5dedf7b56eb7eeb20b0da2252d9a1087b1
Author: Serge Hallyn <serge.hallyn at ubuntu.com>
Date: Fri Jan 11 12:39:31 2013 -0600
remove logfile and loglevel from struct lxc_conf
The options are still supported in the lxc configuration file.
However they are stored only in local variables in src/lxc/log.c,
which can be read using two new functions:
int lxc_log_get_level(void);
const char *lxc_log_get_file(void);
Changelog: jan 14:
have lxc_log_init use lxc_log_set_file(), have lxc_log_set_file() take
a const char *, and have it keep its own strdup'd copy of the filename.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
commit f15b77ca275852cf6d6a34e2e98b29737ed32cb1
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Sun Jan 13 15:29:26 2013 -0500
lxcutmp.c: Fix typo causing build failure
In a previous change I added an ifdef for HAVE_SYS_TIMERFD_h
rather than HAVE_SYS_TIMERFD_H, leading to a missing include of
sys/timerfd.h on platforms that support it and ultimately to a build
failure.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
commit 740ee8c7754f68bc6a467bd298c9589647f4d92b
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Fri Jan 11 15:53:14 2013 -0500
Fix check for openpty
The previous implementation of the openpty check was always returning
'no' as openpty is typically defined in util.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
commit e316c085399d1cb487ae302e05fbf241df4eb615
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Fri Jan 11 12:29:55 2013 -0500
Build lxcutmp.c without timerfd.h or utmpx.h
This adds a local implementation of the bits we need form timerfd.h and
utmpx.h so that the LXC utmp watch can be used with libc that don't implement
the same functions as eglibc.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 565c2d76a30d29ecce76ca595cf79dd1e528399e
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Fri Jan 11 12:29:54 2013 -0500
Rename utmp.c/utmp.h to lxcutmp.c/lxcutmp.h
This avoids conflict with the system header utmp.h.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 9be380b07b1e05505469f213cf5a4612abe2dd53
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Fri Jan 11 12:29:53 2013 -0500
Add check for sys/timerfd.h
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit a45bbcedb2ee8e97e81e40c449050beed74295b9
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Fri Jan 11 12:29:52 2013 -0500
Fix header name in lxcmntent.h
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 59ec0a36c7b5e0c60eab1a626d2af24a96de5c5c
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Thu Jan 10 15:45:22 2013 -0500
use pkg-config to ensure python3-devel is installed
The Python.h header varies in location by distribution, so instead use
pkg-config to ensure the python3 devel package is installed. Tested with
Ubuntu 12.04 and Fedora 17. Fixes --enable-python on Fedora 17.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 148315348760faf4ad822ded7c416d2de8050937
Author: Alexander Vladimirov <alexander.idkfa.vladimirov at gmail.com>
Date: Fri Jan 11 18:36:23 2013 +0800
Add 'config' option to lxc-archlinux template and fix getopt string
This option allows user to control installation repository and options
using alternative pacman configuration file.
Also remove unnecessary sed invocation during container configuration.
Signed-off-by: Alexander Vladimirov <alexander.idkfa.vladimirov at gmail.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit f298ee50b8cfa46f20138f95ca916ec4b54c9a45
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 10 17:10:51 2013 -0500
utmp.h: Don't fail when utmpx.h isn't present
Following a comment on the mailing-list, I made utmp.h return -1
when it's disabled, the problem with that is that it prevents the
container from starting completely, which isn't quite what I wanted.
This change makes the function succeed, the container will therefore
start but without utmp handler.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit cbec003096b98bd62e46bae9f3a2fce90b06e650
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 10 15:22:30 2013 -0500
Define PR_CAPBSET_READ when missing
PR_CAPBSET_READ isn't defined in bionic, so define it if it's not.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit ed34a67d010fd353812bceb70940bcb6c35a51a3
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Wed Jan 9 14:09:55 2013 -0500
oracle template: fix lxc-shutdown with upstart SIGPWR handler
OL6 uses upstart init and needs a handler for the SIGPWR that
lxc-shutdown sends it so that a container can shut down cleanly.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit e9f2c74c3da6823c2530a6078545f785d192076c
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Wed Jan 9 14:09:33 2013 -0500
fix lxc-shutdown argument parsing
processing of -w or -r shifts an argument that isn't there, messing up
other argument processing
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 7af3759fea144f73ddf1c2c7c35d468a2b8ba133
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Mon Jan 7 17:46:16 2013 -0500
Makefile.am: Add missing liblxc symlink
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit c1dc38c2e805cc82489d442185ad57d8334bde76
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Fri Jan 4 13:56:13 2013 -0500
Don't call setup_mount_entries if the list is empty
There's no good reason to call setup_mount_entries if we don't have any
lxc.mount.entry. This also avoids an issue on bionic where the tmpfile()
call in setup_mount_entries requires the presence of /tmp which isn't the
case by default.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit fd5c4f905861964cb473cf3df3336447a9365962
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 14:04:48 2013 -0500
tests/Makefile.am: Update for bionic
-lpthread doesn't exist and isn't necessary on bionic.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 5c0f1b3b2fb0653a4463e005bfc39b9b6d2934fd
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 11:51:52 2013 -0500
lxc_unshare: Replace getpw*_r by getpw*
Bionic and maybe some other libc implementations lack the _r nss functions.
This replaces our current getpwnam_r and getpwuid_r calls by getpwnam and
getpwuid.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 72f919c42a7b327b92b03206662ba3accad31bae
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:20 2013 -0500
conf.c: Cleanup __S_ISTYPE
__S_ISTYPE doesn't exist in all C libraries, so define it if it's missing.
Additionaly, replace one occurence where it wasn't actually needed.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit edaf8b1bf1ca57202af0ffb53dcd665b01695888
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:19 2013 -0500
Add local implementation of mntent.h
Bionic (at least) is missing some of the usual mntent functions.
This adds code defining those that we need when they're missing from the C
library.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit c4b790845d76edd2ed2f7ed8973dc194be38123a
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:18 2013 -0500
caps.h: Rename __errno to ___errno
At least bionic defines __errno, so this was causing a conflict in caps.h
leading to build failure. Renaming to ___errno avoids that conflicting
definition.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 956edc54969dc3e3653ea3e410522eb1def22588
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Wed Dec 26 15:47:37 2012 +0100
Replace strdupa call by standard strdup
strdupa appears to only exist in the standard glibc but at least not in bionic.
Replace the two strdupa calls we have by a standard strdup.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit da9dd0f14d91713d48465b7cbf8bc05922d2415f
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:16 2013 -0500
Add a bionic_alphasort function on bionic
alphasort doesn't have the right signature on bionic which causes the build to
fail. This implements a new bionic_alphasort function when building on bionic
providing the right signature and a functional equivalent of glibc's alphasort.
This signature problem with alphasort was fixed in upstream bionic but hasn't
been released yet. This commit can therefore be reverted as soon as the
following commit hits the Android NDK: 40e467ec668b59be25491bd44bf348a884d6a68d
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit ffbf58150c7a12ea2a133507f5f400ff3c839c12
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:15 2013 -0500
Make utmpx.h optional
This adds code detecting the presence of utmpx.h and in its absence, turns the
utmp related functions into no-ops.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 2d76d1d7e5fc15693e086ca46dc06ef0fd74806e
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:14 2013 -0500
Workaround missing functions in other libc
Some libc implementation (bionic) is lacking some of the syscall functions
that are present in the glibc.
For those, detect at build time the they are missing and implement a minimal
syscall() wrapper that will essentially give the same result as the glibc
function.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 6ff05e18a3fcda14df31d833612bddee4bb09534
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:13 2013 -0500
personality.h: Make the personality code optional
Some platforms don't have personality.h in their C library, this change
adds buildtime detection for the header and turns off the personality setting
code in those cases.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 495d2046f6fd0143e368f59746c6d24cef8ad87f
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Dec 20 16:11:03 2012 +0100
Don't hard depend on capability.h and libcap
In the effort to make LXC work with non-standard Linux distros, this change
allows for the user to build LXC without capability support through a new
--disable-capabilities option to configure.
This effectively will cause LXC not to link against libcap and will turn all
the _cap_ functions into no-ops.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit e827ff7e2f3c1c18e5823312482f0f45e03cb6a8
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:11 2013 -0500
tty.h: Ship our own minimal openpty.h
bionic is missing an openpty() function, so ship our own and only
build it and use it on bionic.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 1f1665e6caa1835a2c5c5e369d69b8fa225effe3
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:10 2013 -0500
clone: Support bionic's clone() defintion
The clone() call in bionic is very slightly different.
This updates namespace.h to support both glibc and bionic.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 9818cae412c5446ec9ec86127c97d7e3822bd459
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:09 2013 -0500
conf.c: Define LO_FLAGS_AUTOCLEAR if it's not
LO_FLAGS_AUTOCLEAR isn't defined on bionic, so add an extra ifndef
and set it to its usual value if it's not.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 8173e600ef80d3f3685a6f1f933ab92f09a160c9
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Dec 20 14:17:09 2012 +0100
Add/remove extra includes
While cross-building with bionic, a number of failures were triggered by some
missing includes and in a few cases by extra unused includes.
This commit updates the various headers based on those observations.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit d2717c14d8bb06967a6817d7909a2ee87b523002
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:07 2013 -0500
Replace get_current_dir_name by getcwd
get_current_dir_name appears to be specific to glibc. Replace that call
by an equivalent getcwd call.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 20d2e91bd3495f4368396cd13a0507d716703286
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Jan 3 12:24:06 2013 -0500
No need to link against rt and util on bionic
When building on bionic, -lrt and -lutil only cause a build failure.
Dropping those fixes the build, so it appears that the symbols are defined
in the main library.
This commit moves -lrt and -lutil under a !IS_BIONIC check.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 1ba0013f21e1953ae4a59cdf61562fbe843077e9
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Thu Dec 20 13:46:57 2012 +0100
Support both getline and fgetln
Some libc implementations don't have the getline function but instead
have an equivalent fgetln function.
Add code to detect both and use whatever is available.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 7c11d57a22668c838ecec57372a3534b5c956400
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Tue Jan 8 12:02:53 2013 -0500
Replace all reference to ushort by unsigned short
ushort appears to be a glibc specific type which doesn't exist in
bionic, this commit simply replace all occurences by the equivalent
unsigned short type.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 8aa4885c224acf396a9413a272b97928f7345ede
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Tue Jan 8 12:02:52 2013 -0500
configure.ac: Cleanup, comments, indent, ...
This commit doesn't do any functional change to configure.ac but does a fair
amount of cleaning up.
It re-orders the various blocks by type (options, checks, expands, ...).
It also consistently uses tabs for indents.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit a6168a17ee9d7fb3f3eaec61c0db724bf877afdc
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Tue Jan 8 12:02:51 2013 -0500
configure.ac: Add code to detect bionic C library
This adds a new IS_BIONIC define that can be used to detect whether we are
building with eglibc or with bionic.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 3a32201c5a442c2732861aeee1a5f70909718b90
Author: Alexander Vladimirov <alexander.idkfa.vladimirov at gmail.com>
Date: Tue Jan 8 09:08:54 2013 +0800
Set umask before populating /dev and restore it after.
According to docs, mknod clears each permission bit whose
corresponding bit in the process umask is set, so we should fix it
before creating device nodes.
Signed-off-by: Alexander Vladimirov <alexander.idkfa.vladimirov at gmail.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit c5b908a262d30dfc6a5969b22a7e25fe167447fd
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Mon Jan 7 14:02:39 2013 -0500
oracle template: use url arg to wget repo file
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit d378aebe3da108502ea5ff8fc134491214135057
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Mon Jan 7 14:02:31 2013 -0500
oracle template: drop additional capabilities
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 768487891f16c539954f871ef2e36ebd5556ccb2
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Fri Jan 4 15:23:23 2013 -0500
document lxc-console escape sequence and argument
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 29e18143a07ffab7e85cb8db4dc39d394f0c6ea0
Author: Maximilian Seesslen <mes at seesslen.net>
Date: Fri Jan 4 16:36:07 2013 +0100
fixed RELEASE_URL for fedora releases higher than 16
The Url for the fedora-release RPM changed in release 17.
Signed-off-by: Maximilian Seesslen <mes at seesslen.net>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit bd9a66b20c33dda261e794b4aa19c653cb7a98c8
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Fri Jan 4 09:39:04 2013 +0100
lxc-ps: fix order of output and fix --lxc opt
We must output the lines from 'ps' in same order for tree views.
Fix also --lxc option to only show processes from containers.
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit bc2333ebeca7a2443c7c4a004dc6dd25e9aba15c
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Tue Dec 25 16:50:54 2012 +0100
lxc-checkconfig: fix colors when using dash
The \e did not work as expected on dash. Replace with proper posix \033
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit d27b0806cdd7f4bf45a83b9c3dc97320ac18f492
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Tue Dec 18 19:15:33 2012 -0500
fix lxc-wait waiting forever for FREEZING, FROZEN, THAWED states
These states are kept by the kernel in the freezer.state cgroup item, and
are never set in handler->state with lxc_set_state(). If lxc transitions
a container to/from the freezer after an lxc-wait for one of the above
states has already started, the lxc-wait will never see the new state. This
change has lxc send the new state to the lxc-monitor socket.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit e35cb41b8c187980825c9be2c628a137ffeeee6b
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Fri Dec 14 15:38:35 2012 -0500
oracle template: add support for creating ol4 container from ovm template
Also: disable the interactive part of ovmd so ol5,6 containers won't
hang if started for the first time with -d. Don't let containers do rawio,
or have access to /dev/rtc0, they can mess up the hosts system clock among
other things.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 596a818d4b8b55586d36af518b745cd96b24c67a
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Thu Dec 27 17:01:26 2012 -0500
separate console device from console log
lxc-start -c makes the named file/device the container's console, but using
this with a regular file in order to get a log of the console output does
not work very well if you also want to login on the console. This change
implements an additional option (-L) to simply log the console's output to
a file.
Both options can be used separately or together. For example to get a usable
console and log: lxc-start -n name -c /dev/tty8 -L console.log
The console state is cleaned up more when lxc_delete_console is called, and
some of the clean up paths in lxc_create_console were fixed.
The lxc_priv and lxc_unpriv macros were modified to make use of gcc's local
label feature so they can be expanded more than once in the same function.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
commit 4199da3061d02e9b5087faa16dd875d4bfeb3989
Author: Stéphane Graber <stgraber at ubuntu.com>
Date: Wed Jan 2 13:47:18 2013 -0500
kill -s expects the signal name without SIG
The previous lxc-shutdown change replaced 'kill SIG<name>' by
'kill -s SIG<name>'. Although this works with busybox where it was tested,
this doesn't actually work with all kill implementations. Some requiring just
the signal name without the prefix.
This changes "-s SIG<name>" by just "-s <name>". Tested with busybox and
standard kill.
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
commit 670c6ab8caac48ce5cf043796dd8908114b7f607
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Mon Dec 31 20:49:19 2012 +0100
lxc-alpine: add support for installing optional packages
Let users append a list of packages they want install in the container
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 2b49de9a3ff182c208148d780f6b26cf8cdd09d8
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Mon Dec 31 20:49:18 2012 +0100
lxc-alpine: add support for setting arch from command line
This allows us to lxc-create 32 bit guests on x86_64 hosts.
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit e5846a6f89db72bdbf3d651e5faf232045d17af8
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Mon Dec 31 20:49:17 2012 +0100
lxc-alpine: add --repository option
This allows specifying what repository to use for the container.
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit b1aa0624bae5a81d6f6bbc2653a388d148cffef8
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Mon Dec 31 20:49:16 2012 +0100
lxc-alpine: indent fixes
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 8410c48507cdd72fb13f1d4476f63f0d5c75e359
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Mon Dec 31 20:49:15 2012 +0100
templates: install lxc-alpine
Make sure we actually install lxc-alpine
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit b5dec5f30bdf6137789bd19eee5393ed8b60840e
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Wed Dec 26 22:31:56 2012 +0100
lxc-ps: use posix shell and awk instead of bash
Use awk to parse the output pf 'ps' and the tasks files for the
containers.
Use awk fields to find PID column rather than assume that the PID field
is exactly 5 chars wide and has a leading space ' PID'. This works as
long as the PID field is before the command or other field that include
spaces. This also makes it work with busybox 'ps'.
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 600faead3804e7f507e18bdb41588964b0fc611f
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Thu Dec 27 09:52:30 2012 +0100
lxc-shutdown: use posix shell instead of bash
- avoid getopt --longoptions
- use 'which' instead of 'type' to detect existance of tools
- specify -s SIG<signame> with kill
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 4415d5163c17d462def86566c33910772237e0ce
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Mon Dec 31 14:02:49 2012 -0500
fix open check (0 is a valid fd)
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 7265dc4344d5d0555e9a88467eaee392594e3171
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Fri Dec 28 09:24:55 2012 +0100
cleanup: use lxc-info --state-is
We now have the possibility to test for a given state. Use this feature
instead of parsing output with grep or awk
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 32e869018640e0d898031de20514e0ffca79baa9
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Wed Dec 26 10:07:04 2012 +0100
legacy/lxc-ls: improve finding fs mountpoint of hierarchy
We cannot assume that the mount source name always starts with 'cgroup'
so we check the filesystem type instead.
Use 'awk' instead of 'grep -E' and as it is a better tool for this job.
This fixes the tool on systems using openrc.
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit f358385a7cf0ec74925d7f26b8a9dab1225dc2b6
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Wed Dec 26 10:07:03 2012 +0100
lxc-netstat: improve finding fs mountpoint of hierarchy
We cannot assume that the mount source name always starts with 'cgroup'
so we check the filesystem type instead.
Use 'awk' instead of 'grep -E' and as it is a better tool for this job.
This fixes the tool on systems using openrc.
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit f3849d01d8f31785bf933ffcf91a419c4ff2257d
Author: Alexander Vladimirov <alexander.idkfa.vladimirov at gmail.com>
Date: Thu Dec 13 16:00:55 2012 +0800
Update lxc-archlinux template to work with systemd
Use arch-install-scripts for installation.
Signed-off-by: Alexander Vladimirov <alexander.idkfa.vladimirov at gmail.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit c44fc03789973cab0d689617e3c2f7ec02fd29f7
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Tue Dec 25 17:08:56 2012 +0100
lxc-netstat: use posix shell instead of bash
- use case .. in instead of comparison with globs
- avoid 'local'
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 4785915a51890379393e5a87b6c987d7444d4abe
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Tue Dec 25 17:08:55 2012 +0100
lxc-clone: use posix shell instead of bash
- avoid getopt --longoptions
- use 'which' instead of 'type' to detect existance of tools
- use 'grep -q -w' instead of bash substring variable expansion
${line:0:18}
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 2f0e69084ed061dd00e7e1123514800aa7b851b9
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Tue Dec 25 17:08:54 2012 +0100
legacy/lxc-ls: use posix shell instead of bash
- use case .. in instead of comparison with globs
- avoid 'local'
While here, also avoid 'find ... -printf' which is not supported on busybox
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 11bdaa7475f54571537aaf2ba05f78068fac3099
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Tue Dec 25 17:08:53 2012 +0100
lxc-destroy: use posix shell instead of bash
- avoid use getopt --longoptions
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 2a9a0a08077d88ee1d70ca46ca122216f3d1c89a
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Mon Dec 24 17:18:21 2012 +0100
templates: initial support for Alpine Linux
Requires apk-tools (http://git.alpinelinux.org/cgit/apk-tools)
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 5270bf4b088328d6188211eb02909de4a1a04b68
Author: Kyle Russell <bkylerussell at gmail.com>
Date: Fri Dec 21 10:34:34 2012 -0500
Fix compile warning on uninitialized return value
Signed-off-by: Kyle Russell <bkylerussell at gmail.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 859a6da0fac5d214230f8a52777277b5147532fb
Author: Natanael Copa <ncopa at alpinelinux.org>
Date: Tue Dec 25 10:53:50 2012 +0100
define MS_SHARED if needed
Fixes build on uClibc.
Signed-off-by: Natanael Copa <ncopa at alpinelinux.org>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 964fe051e9dc21be6c52ccf5b9ff47a8aea396fc
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Thu Dec 20 16:14:49 2012 -0600
Clear environment for container
Clear env before starting a container. Do it right before setting
the container=lxc variable.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit cc28d0b0a66bd956645dc7b8fc85b917711f2472
Author: Serge Hallyn <serge.hallyn at canonical.com>
Date: Wed Dec 19 23:58:44 2012 -0600
Support MS_SHARED /
(I'll be out until Jan 2, but in the meantime, here is hopefully a
little newyears gift - this seems to allow lxc-start with / being
MS_SHARED on the host)
When / is MS_SHARED (for instance with f18 and modern arch), lxc-start
fails on pivot_root. The kernel enforces that, when doing pivot_root,
the parent of current->fs->root (as well as the new root and the putold
location) not be MS_SHARED.
To work around this, check /proc/self/mountinfo for a 'shared:' in
the '/' line. If it is there, then create a tiny MS_SLAVE tmpfs dir to
serve as parent of /, recursively bind mount / into /root under that dir,
make it rslave, and chroot into it.
Tested with ubuntu raring image after doing 'mount --make-rshared /'.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Acked-by: Stéphane Graber <stgraber at ubuntu.com>
commit 963aef6f7f127c43cded0fe628a1b00fe9afb16e
Author: Dwight Engen <dwight.engen at oracle.com>
Date: Tue Dec 18 16:12:34 2012 -0500
lxc-destroy container only if it is in the STOPPED state
Currently, lxc-destory will attempt to destroy a container if it is not in
the RUNNING state, but doing so is not good when the container is FROZEN, or
in other transitional states.
Signed-off-by: Dwight Engen <dwight.engen at oracle.com>
Acked-by: Serge E. Hallyn <serge.hallyn at ubuntu.com>
-----------------------------------------------------------------------
Summary of changes:
.gitignore | 3 +-
Makefile.am | 11 +-
README | 2 +-
config/Makefile.am | 14 +-
config/{lxc.conf.libvirt => default.conf.libvirt} | 0
config/{lxc.conf.ubuntu => default.conf.ubuntu} | 0
config/{lxc.conf.unknown => default.conf.unknown} | 0
configure.ac | 276 ++++++++-----
doc/Makefile.am | 31 +-
...xc-unfreeze.sgml.in => lxc-checkconfig.sgml.in} | 44 +--
doc/lxc-clone.sgml.in | 194 +++++++++
doc/lxc-console.sgml.in | 23 +-
doc/{lxc-ls.sgml.in => lxc-device.sgml.in} | 109 ++----
doc/{lxc-wait.sgml.in => lxc-info.sgml.in} | 117 +++---
doc/lxc-ls.sgml.in | 2 +
doc/{legacy/lxc-ls.sgml.in => lxc-netstat.sgml.in} | 55 +--
doc/lxc-ps.sgml.in | 2 +-
...{lxc-ls.sgml.in => lxc-start-ephemeral.sgml.in} | 104 +++--
doc/lxc-start.sgml.in | 28 +-
doc/lxc-top.sgml.in | 164 ++++++++
doc/{lxc-cgroup.sgml.in => lxc-unshare.sgml.in} | 112 +++---
doc/{lxc-unfreeze.sgml.in => lxc-version.sgml.in} | 42 +--
doc/lxc.conf.sgml.in | 162 ++++++++
lxc.spec.in | 28 ++-
src/Makefile.am | 2 +-
src/include/getline.c | 31 ++
src/include/getline.h | 6 +
src/include/lxcmntent.c | 173 ++++++++
src/include/lxcmntent.h | 32 ++
src/include/openpty.c | 72 ++++
src/include/openpty.h | 14 +
src/lua-lxc/Makefile.am | 26 ++
src/lua-lxc/core.c | 412 +++++++++++++++++++
src/lua-lxc/lxc.lua | 424 ++++++++++++++++++++
src/lua-lxc/test/apitest.lua | 326 +++++++++++++++
src/lxc/Makefile.am | 61 +++-
src/lxc/arguments.h | 1 +
src/lxc/attach.c | 34 ++-
src/lxc/caps.c | 10 +-
src/lxc/caps.h | 44 ++-
src/lxc/cgroup.c | 9 +-
src/lxc/commands.c | 64 ++-
src/lxc/commands.h | 11 +-
src/lxc/conf.c | 399 ++++++++++++++++---
src/lxc/conf.h | 43 ++-
src/lxc/confile.c | 163 ++++++---
src/lxc/confile.h | 2 +
src/lxc/console.c | 74 +++-
src/lxc/execute.c | 4 +-
src/lxc/freezer.c | 6 +
src/lxc/legacy/lxc-ls.in | 22 +-
src/lxc/log.c | 162 +++++++-
src/lxc/log.h | 8 +-
src/lxc/lxc-checkconfig.in | 8 +-
src/lxc/lxc-clone.in | 69 ++--
src/lxc/lxc-create.in | 11 +-
src/lxc/lxc-destroy.in | 48 ++-
src/lxc/lxc-netstat.in | 19 +-
src/lxc/lxc-ps.in | 97 +++--
src/lxc/lxc-setcap.in | 133 ------
src/lxc/lxc-setuid.in | 130 ------
src/lxc/lxc-shutdown.in | 60 ++--
src/lxc/lxc-top | 242 +++++++++++
src/lxc/lxc.functions.in | 33 ++
src/lxc/lxc.h | 13 +-
src/lxc/lxc_attach.c | 18 +-
src/lxc/lxc_cgroup.c | 2 +-
src/lxc/lxc_checkpoint.c | 2 +-
src/lxc/lxc_console.c | 6 +-
src/lxc/lxc_execute.c | 13 +-
src/lxc/lxc_freeze.c | 2 +-
src/lxc/lxc_info.c | 8 +-
src/lxc/lxc_init.c | 2 +-
src/lxc/lxc_kill.c | 6 +-
src/lxc/lxc_monitor.c | 2 +-
src/lxc/lxc_restart.c | 11 +-
src/lxc/lxc_start.c | 111 +++--
src/lxc/lxc_stop.c | 7 +-
src/lxc/lxc_unfreeze.c | 2 +-
src/lxc/lxc_unshare.c | 29 +-
src/lxc/lxc_wait.c | 4 +-
src/lxc/lxccontainer.c | 147 ++++++--
src/lxc/lxccontainer.h | 17 +-
src/lxc/lxclock.c | 1 +
src/lxc/{utmp.c => lxcutmp.c} | 69 ++++
src/lxc/{utmp.h => lxcutmp.h} | 2 +
src/lxc/namespace.c | 1 -
src/lxc/namespace.h | 9 +-
src/lxc/network.c | 2 +-
src/lxc/network.h | 2 +-
src/lxc/nl.c | 2 +-
src/lxc/nl.h | 2 +-
src/lxc/parse.c | 23 +
src/lxc/restart.c | 4 +-
src/lxc/start.c | 150 ++++++-
src/lxc/start.h | 5 +-
src/lxc/state.c | 12 +-
src/lxc/state.h | 2 +-
src/lxc/stop.c | 6 +-
src/lxc/sync.h | 2 +
src/lxc/utils.c | 58 +++-
src/lxc/utils.h | 7 +-
src/python-lxc/Makefile.am | 2 +
src/python-lxc/lxc.c | 42 ++-
src/python-lxc/lxc/__init__.py.in | 20 +-
src/tests/Makefile.am | 11 +-
src/tests/containertests.c | 6 +-
src/tests/createtest.c | 2 +-
src/tests/destroytest.c | 4 +-
src/tests/get_item.c | 8 +-
src/tests/getkeys.c | 2 +-
src/tests/lxcpath.c | 85 ++++
src/tests/saveconfig.c | 4 +-
src/tests/shutdowntest.c | 2 +-
src/tests/startone.c | 4 +-
templates/Makefile.am | 5 +-
templates/lxc-alpine.in | 219 ++++++++++
templates/lxc-archlinux.in | 365 ++++-------------
templates/lxc-busybox.in | 35 ++-
templates/lxc-fedora.in | 6 +-
templates/lxc-oracle.in | 221 ++++++++---
templates/lxc-ubuntu.in | 8 +-
122 files changed, 5220 insertions(+), 1600 deletions(-)
rename config/{lxc.conf.libvirt => default.conf.libvirt} (100%)
rename config/{lxc.conf.ubuntu => default.conf.ubuntu} (100%)
rename config/{lxc.conf.unknown => default.conf.unknown} (100%)
copy doc/{lxc-unfreeze.sgml.in => lxc-checkconfig.sgml.in} (68%)
create mode 100644 doc/lxc-clone.sgml.in
copy doc/{lxc-ls.sgml.in => lxc-device.sgml.in} (52%)
copy doc/{lxc-wait.sgml.in => lxc-info.sgml.in} (57%)
copy doc/{legacy/lxc-ls.sgml.in => lxc-netstat.sgml.in} (66%)
copy doc/{lxc-ls.sgml.in => lxc-start-ephemeral.sgml.in} (55%)
create mode 100644 doc/lxc-top.sgml.in
copy doc/{lxc-cgroup.sgml.in => lxc-unshare.sgml.in} (50%)
copy doc/{lxc-unfreeze.sgml.in => lxc-version.sgml.in} (68%)
create mode 100644 src/include/getline.c
create mode 100644 src/include/getline.h
create mode 100644 src/include/lxcmntent.c
create mode 100644 src/include/lxcmntent.h
create mode 100644 src/include/openpty.c
create mode 100644 src/include/openpty.h
create mode 100644 src/lua-lxc/Makefile.am
create mode 100644 src/lua-lxc/core.c
create mode 100755 src/lua-lxc/lxc.lua
create mode 100755 src/lua-lxc/test/apitest.lua
mode change 100644 => 100755 src/lxc/lxc-clone.in
delete mode 100644 src/lxc/lxc-setcap.in
delete mode 100644 src/lxc/lxc-setuid.in
create mode 100755 src/lxc/lxc-top
create mode 100644 src/lxc/lxc.functions.in
rename src/lxc/{utmp.c => lxcutmp.c} (89%)
rename src/lxc/{utmp.h => lxcutmp.h} (97%)
create mode 100644 src/tests/lxcpath.c
create mode 100644 templates/lxc-alpine.in
hooks/post-receive
--
lxc
More information about the lxc-devel
mailing list