]> git.ipfire.org Git - thirdparty/lxc.git/log
thirdparty/lxc.git
7 years agostart: s/||/&&/ when mapping ids 2163/head
Christian Brauner [Tue, 13 Feb 2018 23:19:42 +0000 (00:19 +0100)] 
start: s/||/&&/ when mapping ids

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocgfsng: simplifications and fixes
Christian Brauner [Tue, 13 Feb 2018 20:00:46 +0000 (21:00 +0100)] 
cgfsng: simplifications and fixes

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge pull request #2162 from brauner/2018-02-10/remove_openpty_lock
Stéphane Graber [Tue, 13 Feb 2018 18:53:03 +0000 (13:53 -0500)] 
Merge pull request #2162 from brauner/2018-02-10/remove_openpty_lock

lxclock: remove atfork handlers

7 years agotree-wide: remove cgmanager 2162/head
Christian Brauner [Tue, 13 Feb 2018 04:37:48 +0000 (05:37 +0100)] 
tree-wide: remove cgmanager

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agolxclock: remove pthread_atfork_handlers
Christian Brauner [Sat, 10 Feb 2018 22:25:18 +0000 (23:25 +0100)] 
lxclock: remove pthread_atfork_handlers

They shouldn't be needed anymore.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge branch 'tanyifeng-support_mount_propagation' into lxc/master
Christian Brauner [Mon, 12 Feb 2018 09:58:24 +0000 (10:58 +0100)] 
Merge branch 'tanyifeng-support_mount_propagation' into lxc/master

7 years agoconf: support mount propagation
Yifeng Tan [Mon, 12 Feb 2018 12:01:32 +0000 (20:01 +0800)] 
conf: support mount propagation

Closes #810.

Signed-off-by: Yifeng Tan <tanyifeng1@huawei.com>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge pull request #2158 from lifeng68/Fix_lxc-console
Christian Brauner [Mon, 12 Feb 2018 07:41:51 +0000 (08:41 +0100)] 
Merge pull request #2158 from lifeng68/Fix_lxc-console

Fix lxc-console hang

7 years agoFix lxc-console hang 2158/head
LiFeng [Mon, 12 Feb 2018 12:22:47 +0000 (07:22 -0500)] 
Fix lxc-console hang

The variable 'descr' is mistakenly covered with 'descr_console'.

Signed-off-by: LiFeng <lifeng68@huawei.com>
7 years agoMerge pull request #2159 from lifeng68/modify_gitignore
Christian Brauner [Mon, 12 Feb 2018 06:27:37 +0000 (07:27 +0100)] 
Merge pull request #2159 from lifeng68/modify_gitignore

Modify .gitignore

7 years agoModify .gitignore 2159/head
LiFeng [Mon, 12 Feb 2018 14:45:22 +0000 (09:45 -0500)] 
Modify .gitignore

add:
src/lxc/cmd/lxc-checkconfig
src/lxc/cmd/lxc-update-config

Signed-off-by: LiFeng <lifeng68@huawei.com>
7 years agoMerge pull request #2155 from brauner/2018-02-10/remove_legacy_items
Serge Hallyn [Mon, 12 Feb 2018 03:30:28 +0000 (21:30 -0600)] 
Merge pull request #2155 from brauner/2018-02-10/remove_legacy_items

tree-wide: remove legacy codepaths

7 years agotree-wide: remove legacy codepaths 2155/head
Christian Brauner [Sat, 10 Feb 2018 23:12:36 +0000 (00:12 +0100)] 
tree-wide: remove legacy codepaths

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge pull request #2090 from brauner/2018-01-12/tools_remove_non_api_symbols
Stéphane Graber [Sun, 11 Feb 2018 22:52:01 +0000 (17:52 -0500)] 
Merge pull request #2090 from brauner/2018-01-12/tools_remove_non_api_symbols

tools: remove non api symbols

7 years agoMerge pull request #2150 from brauner/2018-02-10/cgfsng_fix_unpriv_devices
Stéphane Graber [Sat, 10 Feb 2018 20:32:14 +0000 (15:32 -0500)] 
Merge pull request #2150 from brauner/2018-02-10/cgfsng_fix_unpriv_devices

conf: fix clearing cgroup settings

7 years agoMerge pull request #2151 from brauner/2018-02-10/remove_openpty_lock
Stéphane Graber [Sat, 10 Feb 2018 20:31:34 +0000 (15:31 -0500)] 
Merge pull request #2151 from brauner/2018-02-10/remove_openpty_lock

console: they are really not necessary

7 years agoconsole: they are really not necessary 2151/head
Christian Brauner [Sat, 10 Feb 2018 11:54:31 +0000 (12:54 +0100)] 
console: they are really not necessary

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoconf: fix clearing cgroup settings 2150/head
Christian Brauner [Sat, 10 Feb 2018 11:16:41 +0000 (12:16 +0100)] 
conf: fix clearing cgroup settings

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge pull request #2144 from brauner/2018-02-08/coverity_bug_smash
Stéphane Graber [Fri, 9 Feb 2018 15:36:34 +0000 (10:36 -0500)] 
Merge pull request #2144 from brauner/2018-02-08/coverity_bug_smash

coverity: bug smash

7 years agoMerge pull request #2149 from tych0/fix-userns-error-handling
Christian Brauner [Fri, 9 Feb 2018 13:49:11 +0000 (14:49 +0100)] 
Merge pull request #2149 from tych0/fix-userns-error-handling

fix userns helper error handling

7 years agofix userns helper error handling 2149/head
Tycho Andersen [Fri, 9 Feb 2018 13:26:31 +0000 (13:26 +0000)] 
fix userns helper error handling

In both of these cases if there is actually an error, we won't close the
pipe and the api call will hang. Instead, let's be sure to close the pipe
before waiting, so that it doesn't hang.

Signed-off-by: Tycho Andersen <tycho@tycho.ws>
7 years agoMerge branch 'duguhaotian-new' into lxc/master
Christian Brauner [Fri, 9 Feb 2018 11:12:10 +0000 (12:12 +0100)] 
Merge branch 'duguhaotian-new' into lxc/master

7 years agoconf: fix log message
duguhaotian [Fri, 9 Feb 2018 10:50:51 +0000 (18:50 +0800)] 
conf: fix log message

Signed-off-by: duguhaotian <duguhaotian@gmail.com>
7 years agocoverity: #1425971 2144/head
Christian Brauner [Thu, 8 Feb 2018 15:06:31 +0000 (16:06 +0100)] 
coverity: #1425971

Dereference after null check

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocoverity: #1426083
Christian Brauner [Thu, 8 Feb 2018 15:04:03 +0000 (16:04 +0100)] 
coverity: #1426083

Dereference after null check

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agolxccontainer: satisfy coverity
Christian Brauner [Thu, 8 Feb 2018 14:57:02 +0000 (15:57 +0100)] 
lxccontainer: satisfy coverity

The container name can't be NULL so don't give coverity the impression that it
could be.

Silences coverity #1426123.
Silences coverity #1426124.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agostart: use goto instead of simple return
Christian Brauner [Thu, 8 Feb 2018 14:48:15 +0000 (15:48 +0100)] 
start: use goto instead of simple return

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocoverity: #1426126
Christian Brauner [Thu, 8 Feb 2018 14:47:32 +0000 (15:47 +0100)] 
coverity: #1426126

Unchecked return value

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocoverity: #1426734
Christian Brauner [Thu, 8 Feb 2018 14:42:16 +0000 (15:42 +0100)] 
coverity: #1426734

Argument cannot be negative

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocoverity: #1429139
Christian Brauner [Thu, 8 Feb 2018 14:31:59 +0000 (15:31 +0100)] 
coverity: #1429139

Resource leak

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge pull request #2143 from brauner/2018-02-08/fix_cgroup_ns
Stéphane Graber [Thu, 8 Feb 2018 23:07:51 +0000 (18:07 -0500)] 
Merge pull request #2143 from brauner/2018-02-08/fix_cgroup_ns

start: check for cgroup namespace support

7 years agostart: check for cgroup namespace support 2143/head
Christian Brauner [Thu, 8 Feb 2018 22:47:10 +0000 (23:47 +0100)] 
start: check for cgroup namespace support

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge pull request #2142 from hallyn/2018-02-08/priv
Christian Brauner [Thu, 8 Feb 2018 22:40:50 +0000 (23:40 +0100)] 
Merge pull request #2142 from hallyn/2018-02-08/priv

2018 02 08/priv

7 years agoRestore most cases of am_guest_unpriv 2142/head
Serge Hallyn [Thu, 8 Feb 2018 19:04:23 +0000 (13:04 -0600)] 
Restore most cases of am_guest_unpriv

The only cases where we really need to be privileged with respect
to the host is when we are trying to mknod, and in some cases
to do with a physical network device.  This patch leaves the
detection of the network device cases as a TODO.

This should fix the currently broken case of starting a privileged
container with at least one veth nic, nested inside an unprivileged
container.

Cc: Tycho Andersen <tycho@tycho.ws>
Signed-off-by: Serge Hallyn <shallyn@cisco.com>
7 years agodefine am_guest_unpriv
Serge Hallyn [Thu, 8 Feb 2018 18:06:39 +0000 (12:06 -0600)] 
define am_guest_unpriv

Sometimes we want to know whether we are privileged wrt our
namespaces, and sometimes we want to know whether we are priv
wrt init_user_ns.

Signed-off-by: Serge Hallyn <shallyn@cisco.com>
7 years agoMerge pull request #2125 from brauner/2018-02-02/add_namespace_configs
Stéphane Graber [Thu, 8 Feb 2018 15:26:57 +0000 (10:26 -0500)] 
Merge pull request #2125 from brauner/2018-02-02/add_namespace_configs

confile: add lxc.namespace.share.[namespace], lxc.namespace.keep, lxc.namespace.clone

7 years agoMerge pull request #2137 from brauner/2018-02-07/fix_unprivileged_flag
Stéphane Graber [Thu, 8 Feb 2018 15:26:09 +0000 (10:26 -0500)] 
Merge pull request #2137 from brauner/2018-02-07/fix_unprivileged_flag

tools/lxc-ls: fix logic for unpriv containers

7 years agoMerge pull request #2140 from brauner/2018-02-08/cgfsng_fix_ro_remount
Stéphane Graber [Thu, 8 Feb 2018 15:25:50 +0000 (10:25 -0500)] 
Merge pull request #2140 from brauner/2018-02-08/cgfsng_fix_ro_remount

cgfsng: add required remount flags

7 years agotools/lxc_unshare: satisfy Android 2090/head
Christian Brauner [Thu, 8 Feb 2018 14:23:49 +0000 (15:23 +0100)] 
tools/lxc_unshare: satisfy Android

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocgfsng: add required remount flags 2140/head
Christian Brauner [Thu, 8 Feb 2018 10:36:41 +0000 (11:36 +0100)] 
cgfsng: add required remount flags

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=9566d6742852c527bf5af38af5cbb878dad75705

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge branch 'marcosps-selinux_simplification' into lxc/master
Christian Brauner [Thu, 8 Feb 2018 09:50:10 +0000 (10:50 +0100)] 
Merge branch 'marcosps-selinux_simplification' into lxc/master

7 years agolsm: fix missing @ in function documentation
Marcos Paulo de Souza [Wed, 7 Feb 2018 15:06:43 +0000 (13:06 -0200)] 
lsm: fix missing @ in function documentation

Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
7 years agoselinux: simplify check for default label
Marcos Paulo de Souza [Wed, 7 Feb 2018 14:51:38 +0000 (12:51 -0200)] 
selinux: simplify check for default label

Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge branch 'marcosps-issue_870' into lxc/master
Christian Brauner [Thu, 8 Feb 2018 09:34:54 +0000 (10:34 +0100)] 
Merge branch 'marcosps-issue_870' into lxc/master

7 years agocgroups: add check for lxc.cgroup.use
Marcos Paulo de Souza [Thu, 8 Feb 2018 01:55:13 +0000 (23:55 -0200)] 
cgroups: add check for lxc.cgroup.use

Closes #870.

Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
7 years agoinclude: remove getsubopt.*
Christian Brauner [Sun, 21 Jan 2018 21:09:42 +0000 (22:09 +0100)] 
include: remove getsubopt.*

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools/lxc-ls: fix logic for unpriv containers 2137/head
Christian Brauner [Wed, 7 Feb 2018 20:06:01 +0000 (21:06 +0100)] 
tools/lxc-ls: fix logic for unpriv containers

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotemplates: CentOS fixes
Christian Brauner [Wed, 7 Feb 2018 10:39:19 +0000 (11:39 +0100)] 
templates: CentOS fixes

Issues fixed:
- lxc-centos died about a missing /run directory
- lxc-centos complained about some config files it couldn't modify
- the new container got stuck at startup time for a minute
  (literally), waiting for systemd-remount-fs startup script

Of course it still works for RHEL 6, CentOS 6 and 7 as well. I did not
verify earlier CentOS or RHEL releases.

Signed-off-by: Harald Dunkel <harald.dunkel@aixigo.de>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge branch 'lifeng68-remount_cgroup' into lxc/master
Christian Brauner [Wed, 7 Feb 2018 10:30:40 +0000 (11:30 +0100)] 
Merge branch 'lifeng68-remount_cgroup' into lxc/master

7 years agocgfsng: non-functional changes
Christian Brauner [Wed, 7 Feb 2018 10:27:57 +0000 (11:27 +0100)] 
cgfsng: non-functional changes

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocgfsng: do MS_REMOUNT
LiFeng [Wed, 7 Feb 2018 16:39:59 +0000 (11:39 -0500)] 
cgfsng: do MS_REMOUNT

Perform MS_REMOUNT on mounts with MS_RDONLY.

Signed-off-by: LiFeng <lifeng68@huawei.com>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge branch 'lifeng68-use_env_vars_in_container' into lxc/master
Christian Brauner [Wed, 7 Feb 2018 10:18:42 +0000 (11:18 +0100)] 
Merge branch 'lifeng68-use_env_vars_in_container' into lxc/master

7 years agoattach: non-functional changes
Christian Brauner [Wed, 7 Feb 2018 10:13:48 +0000 (11:13 +0100)] 
attach: non-functional changes

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoattach: set the container's environment variables
l00415420 [Wed, 7 Feb 2018 12:39:28 +0000 (07:39 -0500)] 
attach: set the container's environment variables

Set the same environment variables that were used when starting the container
when attaching to the container.

Signed-off-by: LiFeng <lifeng68@huawei.com>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-monitor to API symbols only
Christian Brauner [Sun, 21 Jan 2018 21:03:47 +0000 (22:03 +0100)] 
tools: move lxc-monitor to API symbols only

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: non-functional changes
Christian Brauner [Sun, 21 Jan 2018 20:54:35 +0000 (21:54 +0100)] 
tools: non-functional changes

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocmd: non-functional changes
Christian Brauner [Sun, 21 Jan 2018 20:53:51 +0000 (21:53 +0100)] 
cmd: non-functional changes

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-unshare to API symbols only
Christian Brauner [Fri, 12 Jan 2018 16:06:42 +0000 (17:06 +0100)] 
tools: move lxc-unshare to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-wait to API symbols only
Christian Brauner [Fri, 12 Jan 2018 15:36:12 +0000 (16:36 +0100)] 
tools: move lxc-wait to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-unfreeze to API symbols only
Christian Brauner [Fri, 12 Jan 2018 15:30:38 +0000 (16:30 +0100)] 
tools: move lxc-unfreeze to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-top to API symbols only
Christian Brauner [Fri, 12 Jan 2018 15:29:46 +0000 (16:29 +0100)] 
tools: move lxc-top to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-stop to API symbols only
Christian Brauner [Fri, 12 Jan 2018 15:17:46 +0000 (16:17 +0100)] 
tools: move lxc-stop to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-start to API symbols only
Christian Brauner [Fri, 12 Jan 2018 15:04:28 +0000 (16:04 +0100)] 
tools: move lxc-start to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-snapshot to API symbols only
Christian Brauner [Fri, 12 Jan 2018 15:01:10 +0000 (16:01 +0100)] 
tools: move lxc-snapshot to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-ls to API symbols only
Christian Brauner [Fri, 12 Jan 2018 14:47:32 +0000 (15:47 +0100)] 
tools: move lxc-ls to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-info to API symbols only
Christian Brauner [Fri, 12 Jan 2018 14:36:15 +0000 (15:36 +0100)] 
tools: move lxc-info to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-freeze to API symbols only
Christian Brauner [Fri, 12 Jan 2018 14:32:07 +0000 (15:32 +0100)] 
tools: move lxc-freeze to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-execute to API symbols only
Christian Brauner [Fri, 12 Jan 2018 14:31:03 +0000 (15:31 +0100)] 
tools: move lxc-execute to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-device to API symbols only
Christian Brauner [Fri, 12 Jan 2018 13:46:46 +0000 (14:46 +0100)] 
tools: move lxc-device to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-destroy to API symbols only
Christian Brauner [Fri, 12 Jan 2018 13:39:21 +0000 (14:39 +0100)] 
tools: move lxc-destroy to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-create to API symbols only
Christian Brauner [Fri, 12 Jan 2018 13:33:06 +0000 (14:33 +0100)] 
tools: move lxc-create to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-copy to API symbols only
Christian Brauner [Fri, 12 Jan 2018 13:27:23 +0000 (14:27 +0100)] 
tools: move lxc-copy to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocmd: move lxc-console to API symbols only
Christian Brauner [Fri, 12 Jan 2018 13:11:21 +0000 (14:11 +0100)] 
cmd: move lxc-console to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocmd: move lxc-config to API symbols only
Christian Brauner [Fri, 12 Jan 2018 13:08:43 +0000 (14:08 +0100)] 
cmd: move lxc-config to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-clone to API symbols only
Christian Brauner [Fri, 12 Jan 2018 13:05:21 +0000 (14:05 +0100)] 
tools: move lxc-clone to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-checkpoint to API symbols only
Christian Brauner [Fri, 12 Jan 2018 13:02:10 +0000 (14:02 +0100)] 
tools: move lxc-checkpoint to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocmd: move lxc-update-config
Christian Brauner [Fri, 12 Jan 2018 12:56:37 +0000 (13:56 +0100)] 
cmd: move lxc-update-config

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocmd: move lxc-monitord
Christian Brauner [Fri, 12 Jan 2018 12:54:30 +0000 (13:54 +0100)] 
cmd: move lxc-monitord

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocmd: move lxc-user-nic
Christian Brauner [Fri, 12 Jan 2018 12:53:10 +0000 (13:53 +0100)] 
cmd: move lxc-user-nic

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocmd: move lxc-checkconfig
Christian Brauner [Fri, 12 Jan 2018 12:49:55 +0000 (13:49 +0100)] 
cmd: move lxc-checkconfig

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocmd: move init.lxc{.static}
Christian Brauner [Fri, 12 Jan 2018 12:48:07 +0000 (13:48 +0100)] 
cmd: move init.lxc{.static}

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agocmd: move lxc-lxc_usernsexec
Christian Brauner [Fri, 12 Jan 2018 12:46:30 +0000 (13:46 +0100)] 
cmd: move lxc-lxc_usernsexec

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-cgroup to API symbols only
Christian Brauner [Fri, 12 Jan 2018 12:36:12 +0000 (13:36 +0100)] 
tools: move lxc-cgroup to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-autostart to API symbols only
Christian Brauner [Fri, 12 Jan 2018 12:32:04 +0000 (13:32 +0100)] 
tools: move lxc-autostart to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: lxc-autostart: non-functional changes
Christian Brauner [Fri, 12 Jan 2018 12:25:15 +0000 (13:25 +0100)] 
tools: lxc-autostart: non-functional changes

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agotools: move lxc-attach to API symbols only
Christian Brauner [Fri, 12 Jan 2018 12:13:09 +0000 (13:13 +0100)] 
tools: move lxc-attach to API symbols only

Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agodoc: add lxc.namespace.clone + lxc.namespace.keep 2125/head
Christian Brauner [Mon, 5 Feb 2018 17:32:00 +0000 (18:32 +0100)] 
doc: add lxc.namespace.clone + lxc.namespace.keep

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agostart: resolve clone flags
Christian Brauner [Fri, 2 Feb 2018 12:29:06 +0000 (13:29 +0100)] 
start: resolve clone flags

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoconfile: add lxc.namespace.keep
Christian Brauner [Fri, 2 Feb 2018 11:40:55 +0000 (12:40 +0100)] 
confile: add lxc.namespace.keep

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoconfile: add lxc.namespace.clone
Christian Brauner [Fri, 2 Feb 2018 11:38:14 +0000 (12:38 +0100)] 
confile: add lxc.namespace.clone

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoconfile: lxc.namespace.* -> lxc.namespace.share.*
Christian Brauner [Fri, 2 Feb 2018 10:53:51 +0000 (11:53 +0100)] 
confile: lxc.namespace.* -> lxc.namespace.share.*

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
7 years agoMerge pull request #2117 from brauner/2018-01-26/cgroup_v2_support
Serge Hallyn [Tue, 6 Feb 2018 19:19:10 +0000 (13:19 -0600)] 
Merge pull request #2117 from brauner/2018-01-26/cgroup_v2_support

cgroups: add unified hierarchy support

7 years agoMerge pull request #2044 from brauner/2017-12-16/lxc_ls_add_unprivileged_field
Serge Hallyn [Tue, 6 Feb 2018 19:08:49 +0000 (13:08 -0600)] 
Merge pull request #2044 from brauner/2017-12-16/lxc_ls_add_unprivileged_field

tools: add UNPRIVILEGED field in fancy output mode

7 years agoMerge pull request #2130 from tych0/sigterm-handling
Serge Hallyn [Mon, 5 Feb 2018 15:00:27 +0000 (09:00 -0600)] 
Merge pull request #2130 from tych0/sigterm-handling

Sigterm handling

7 years agoMerge pull request #2129 from tych0/sigterm-sigkill
Christian Brauner [Mon, 5 Feb 2018 14:47:07 +0000 (15:47 +0100)] 
Merge pull request #2129 from tych0/sigterm-sigkill

lxc-init: use SIGKILL after alarm timeout

7 years agolxc.init: ignore SIGHUP 2130/head
Tycho Andersen [Mon, 5 Feb 2018 14:19:25 +0000 (14:19 +0000)] 
lxc.init: ignore SIGHUP

see comment for details.

Signed-off-by: Tycho Andersen <tycho@tycho.ws>
7 years agomonitor: send SIGTERM to the container when SIGHUP is received
Tycho Andersen [Mon, 5 Feb 2018 14:17:48 +0000 (14:17 +0000)] 
monitor: send SIGTERM to the container when SIGHUP is received

For the ->execute() case, we want to make sure the application dies when
SIGHUP is received. The next patch will ignore SIGHUP in the lxc monitor,
because tasks inside the container send SIGHUP to init to have it reload
its config sometimes, and we don't want to do that with init.lxc, since it
might actually kill the container if it forwards SIGHUP to the child and
the child can't handle it.

Signed-off-by: Tycho Andersen <tycho@tycho.ws>
7 years agolxc-init: use SIGKILL after alarm timeout 2129/head
Tycho Andersen [Mon, 5 Feb 2018 14:13:18 +0000 (14:13 +0000)] 
lxc-init: use SIGKILL after alarm timeout

d76e3e1 inadvertently switched the alarm timeout from sigterm to sigkill.
We really want sigkill here, so let's bring it back.

Signed-off-by: Tycho Andersen <tycho@tycho.ws>
7 years agoMerge pull request #2126 from flx42/nvidia-visible-devices-change-null-semantic
Christian Brauner [Fri, 2 Feb 2018 15:11:50 +0000 (16:11 +0100)] 
Merge pull request #2126 from flx42/nvidia-visible-devices-change-null-semantic

hooks: change the semantic of NVIDIA_VISIBLE_DEVICES=""

7 years agohooks: change the semantic of NVIDIA_VISIBLE_DEVICES="" 2126/head
Felix Abecassis [Fri, 2 Feb 2018 14:19:13 +0000 (06:19 -0800)] 
hooks: change the semantic of NVIDIA_VISIBLE_DEVICES=""

With LXC, you can override the value of an environment variable to
null, but you can't unset an existing variable.

The NVIDIA hook was previously activated when NVIDIA_VISIBLE_DEVICES
was set to null. As a result, it was not possible to disable the hook
by overriding the environment variable in the configuration.

The hook can now be disabled by setting NVIDIA_VISIBLE_DEVICES to
null or to the new special value "void".

Signed-off-by: Felix Abecassis <fabecassis@nvidia.com>