It looks like VPATH (split source and build directories) builds
are frequently broken. So let's test them on travis-ci.
Personally I use VPATH build in my deployment scripts.
Signed-off-by: Aleksandr Mezin <mezin.alexander@gmail.com>
struct in6_addr is both defined in the C library header <netinet/in.h>
and the Linux kernel header <linux/in6.h>.
lxc_user_nic.c includes both <netinet/in.h> and <linux/if_bridge.h>. The
later one includes <linux/in6.h>.
This breaks build with the musl libc:
error: redefinition of ‘struct in6_addr’
As lxc_user_nic.c does not use any references from <linux/if_bridge.h> it
is safe to remove this header.
Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
In many environments the preference is to configure containers with
apt mirrors that are SSL-secured.
When building containers using the download template this can't be
done unless an insecure mirror is first used to install the
apt-transport-https package, then the sources reconfigured to
use the https URL.
When building containers without using the download template this
can't be done unless the container creator specifically includes
this package in the package list at build time.
It seems more intuitive to me to have the package installed by
default. This patch includes the required package for the minbase
variant only as this is the default.
Signed-off-by: Jesse Pretorius <jesse.pretorius@rackspace.co.uk>
The idea here is that criu can use open_by_handle on a configuration which
will preserve inodes on moves across hosts, but shouldn't do that on
configurations which won't preserve inodes. Before, we forced it to always
be slow, but we don't have to do this.
Signed-off-by: Tycho Andersen <tycho.andersen@canonical.com>
If we don't do this, we'll end up changing the function signatures for the
internal __criu_* functions each time we add a new parameter, which will
get very annoying very quickly. Since we already have the user's arguments
struct, let's just pass that all the way down.
Signed-off-by: Tycho Andersen <tycho.andersen@canonical.com>
When writing out the CRIU exec command, we're bumping up against the buffer
size limit. Let's increase it so we can avoid:
lxc 20160509213229.921 WARN lxc_log - log.c:log_append_logfile:111 - truncated next event from 523 to 512 bytes
Signed-off-by: Tycho Andersen <tycho.andersen@canonical.com>
If the value starts and ends with matching quote characters, those
characters are stripped automatically. Quote characters are the
single quote (') or double quote ("). The quote removal is done after
the whitespace trimming.
This is needed particularly in order that lxc.environment values may
have trailing spaces. However, the quote removal is done for all values
in the parse_line function, as it has non-const access to the value.
Signed-off-by: Stewart Brodie <stewart@metahusky.net>
gentoo.moresecure.conf tries to drop the capability CAP_SYS_RESOURCES.
However, that capability doesn't exist, so the container doesn't start.
Change it to CAP_SYS_RESOURCE, according to capabilities(7).
Also correct the same typo in a comment in slackware.common.conf.
Signed-off-by: Karl-Johan Karlsson <creideiki@ferretporn.se>
I think (?) this may be related to our hanging monitor bug. Let's do this
anyway, as it's probably a good idea.
Signed-off-by: Tycho Andersen <tycho.andersen@canonical.com>
When container init failed for whatever reason, previously it resulted
in a `SystemError: NULL result without error in PyObject_Call`
This will now result in a RuntimeError with the error message
previously printed to stderr.
Signed-off-by: Aron Podrigal <aronp@guaranteedplus.com>