Commit Graph

6411 Commits

Author SHA1 Message Date
l00415420
7385273fc4
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>
2018-02-07 11:04:42 +01:00
Christian Brauner
6ecad2c49b
tools: move lxc-monitor to API symbols only
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:50 +01:00
Christian Brauner
1a80fcdfc7
tools: non-functional changes
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:50 +01:00
Christian Brauner
1194822f0b
cmd: non-functional changes
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:49 +01:00
Christian Brauner
d567a9a7e9
tools: move lxc-unshare to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:49 +01:00
Christian Brauner
b678c6d8a7
tools: move lxc-wait to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:49 +01:00
Christian Brauner
81bba32eda
tools: move lxc-unfreeze to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:49 +01:00
Christian Brauner
adc0914195
tools: move lxc-top to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:48 +01:00
Christian Brauner
52d27da510
tools: move lxc-stop to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:48 +01:00
Christian Brauner
9810df0785
tools: move lxc-start to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:48 +01:00
Christian Brauner
6a3ec2c51e
tools: move lxc-snapshot to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:48 +01:00
Christian Brauner
4b7c0ef8b2
tools: move lxc-ls to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:48 +01:00
Christian Brauner
8765242a3b
tools: move lxc-info to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:48 +01:00
Christian Brauner
49ac7514cf
tools: move lxc-freeze to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:48 +01:00
Christian Brauner
791e7a73a9
tools: move lxc-execute to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:10:45 +01:00
Christian Brauner
23500ef538
tools: move lxc-device to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:34 +01:00
Christian Brauner
e3347eef56
tools: move lxc-destroy to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:34 +01:00
Christian Brauner
e6294545d1
tools: move lxc-create to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:34 +01:00
Christian Brauner
0cb3e3a6dd
tools: move lxc-copy to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:34 +01:00
Christian Brauner
8d313ae1dd
cmd: move lxc-console to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:33 +01:00
Christian Brauner
2e38dc377d
cmd: move lxc-config to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:33 +01:00
Christian Brauner
2f9928f638
tools: move lxc-clone to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:33 +01:00
Christian Brauner
78485176fd
tools: move lxc-checkpoint to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:33 +01:00
Christian Brauner
6a342cab36
cmd: move lxc-update-config
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:33 +01:00
Christian Brauner
b80939349c
cmd: move lxc-monitord
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:33 +01:00
Christian Brauner
1c7507cb44
cmd: move lxc-user-nic
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:32 +01:00
Christian Brauner
48b1dc4cdc
cmd: move lxc-checkconfig
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:32 +01:00
Christian Brauner
2a5ee335a6
cmd: move init.lxc{.static}
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:32 +01:00
Christian Brauner
844d9eac45
cmd: move lxc-lxc_usernsexec
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:32 +01:00
Christian Brauner
744b1eec11
tools: move lxc-cgroup to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:32 +01:00
Christian Brauner
a9ff89baa0
tools: move lxc-autostart to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:32 +01:00
Christian Brauner
a6993015de
tools: lxc-autostart: non-functional changes
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:31 +01:00
Christian Brauner
9267beba7b
tools: move lxc-attach to API symbols only
Closes #2073.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 21:03:29 +01:00
Christian Brauner
46186acdb0
doc: add lxc.namespace.clone + lxc.namespace.keep
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 20:52:18 +01:00
Christian Brauner
8bc8c7159f
start: resolve clone flags
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 20:48:50 +01:00
Christian Brauner
abeb5bba94
confile: add lxc.namespace.keep
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 20:48:50 +01:00
Christian Brauner
1d8d367638
confile: add lxc.namespace.clone
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 20:48:50 +01:00
Christian Brauner
b074bbf179
confile: lxc.namespace.* -> lxc.namespace.share.*
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2018-02-06 20:48:47 +01:00
Serge Hallyn
3fb8253d91
Merge pull request #2117 from brauner/2018-01-26/cgroup_v2_support
cgroups: add unified hierarchy support
2018-02-06 13:19:10 -06:00
Serge Hallyn
d8eb058d08
Merge pull request #2044 from brauner/2017-12-16/lxc_ls_add_unprivileged_field
tools: add UNPRIVILEGED field in fancy output mode
2018-02-06 13:08:49 -06:00
Serge Hallyn
af3f9cc96e
Merge pull request #2130 from tych0/sigterm-handling
Sigterm handling
2018-02-05 09:00:27 -06:00
Christian Brauner
05f2fed731
Merge pull request #2129 from tych0/sigterm-sigkill
lxc-init: use SIGKILL after alarm timeout
2018-02-05 15:47:07 +01:00
Tycho Andersen
186dfb166a lxc.init: ignore SIGHUP
see comment for details.

Signed-off-by: Tycho Andersen <tycho@tycho.ws>
2018-02-05 14:19:25 +00:00
Tycho Andersen
d4b5d7a8b4 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>
2018-02-05 14:17:48 +00:00
Tycho Andersen
60e324aa5b 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>
2018-02-05 14:13:18 +00:00
Christian Brauner
e6bd446c81
Merge pull request #2126 from flx42/nvidia-visible-devices-change-null-semantic
hooks: change the semantic of NVIDIA_VISIBLE_DEVICES=""
2018-02-02 16:11:50 +01:00
Felix Abecassis
b87243830e 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>
2018-02-02 06:19:13 -08:00
Christian Brauner
b046bbab2e
Merge pull request #2120 from stgraber/master
debian: We must use iproute on wheezy
2018-02-01 15:55:25 +01:00
Stéphane Graber
24d871358d
debian: We must use iproute on wheezy
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
2018-02-01 15:44:43 +01:00
Stéphane Graber
0b7ab4c7dc
Merge pull request #2119 from brauner/2018-02-01/fix_android
lsm: do not #ifdefine
2018-02-01 15:26:22 +01:00