[lxc-devel] [lxc/lxc] d8ee92: Create console when the rootfs is NULL

GitHub noreply at github.com
Tue Feb 6 12:38:30 UTC 2018


  Branch: refs/heads/stable-2.0
  Home:   https://github.com/lxc/lxc
  Commit: d8ee923a211595ca6f308f724d37f1ece018e57f
      https://github.com/lxc/lxc/commit/d8ee923a211595ca6f308f724d37f1ece018e57f
  Author: LiFeng <lifeng68 at huawei.com>
  Date:   2018-02-05 (Mon, 05 Feb 2018)

  Changed paths:
    M src/lxc/console.c
    M src/lxc/start.c

  Log Message:
  -----------
  Create console when the rootfs is NULL

Signed-off-by: LiFeng <lifeng68 at huawei.com>


  Commit: 59b13dc1a473abeff40430c6bd126f50811281b2
      https://github.com/lxc/lxc/commit/59b13dc1a473abeff40430c6bd126f50811281b2
  Author: Tycho Andersen <tycho at tycho.ws>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/lxc_init.c

  Log Message:
  -----------
  unlink lxc-init

It's sort of an implementation detail that this exists at all, and we
should probably not pollute the container's mount tables or FS with this.

Signed-off-by: Tycho Andersen <tycho at tycho.ws>


  Commit: 3a5d29ad6bcc92e56969e2d21071cbad751163ea
      https://github.com/lxc/lxc/commit/3a5d29ad6bcc92e56969e2d21071cbad751163ea
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/lxc_init.c

  Log Message:
  -----------
  coverity: #1427668

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 1658ec311195751429b9445f3febe4fd4fa7820d
      https://github.com/lxc/lxc/commit/1658ec311195751429b9445f3febe4fd4fa7820d
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/utils.c

  Log Message:
  -----------
  coverity: #1427639

remove logically dead code

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: d9b2f08719fd0316026b3ff98976bc9ce8162f3a
      https://github.com/lxc/lxc/commit/d9b2f08719fd0316026b3ff98976bc9ce8162f3a
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/attach.c

  Log Message:
  -----------
  coverity: #1427638

avoid (however unlikely) double free

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: d3461599a1f72caf513cc080b76cd6cc396a226c
      https://github.com/lxc/lxc/commit/d3461599a1f72caf513cc080b76cd6cc396a226c
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/conf.c

  Log Message:
  -----------
  coverity: #1427191

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 042bb5ed331c3c6806bcc79fbe382bed13d0bf37
      https://github.com/lxc/lxc/commit/042bb5ed331c3c6806bcc79fbe382bed13d0bf37
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/cgroups/cgfsng.c

  Log Message:
  -----------
  coverity: #1427190

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 3cf0e5f3e185e4a945c41dbb989dfb07d01df197
      https://github.com/lxc/lxc/commit/3cf0e5f3e185e4a945c41dbb989dfb07d01df197
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/monitor.c

  Log Message:
  -----------
  coverity: #1426734

do not call close on bad fd

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 2ee597561e7c4e06696dde20be0e4e3d32f8aa2d
      https://github.com/lxc/lxc/commit/2ee597561e7c4e06696dde20be0e4e3d32f8aa2d
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/lxc_init.c

  Log Message:
  -----------
  coverity: #1426694

remove logically dead code

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 0f6a1cb7e111e9cd7e5ffa74f32be5c17818df9b
      https://github.com/lxc/lxc/commit/0f6a1cb7e111e9cd7e5ffa74f32be5c17818df9b
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/start.c

  Log Message:
  -----------
  start: fix mainloop cleanup goto statements

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: d83e0ffd85d09ecf1cb2974fb59a17ff22bba1bc
      https://github.com/lxc/lxc/commit/d83e0ffd85d09ecf1cb2974fb59a17ff22bba1bc
  Author: LiFeng <lifeng68 at huawei.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M .gitignore

  Log Message:
  -----------
  Modify .gitignore

Add:
src/tests/lxc-test-api-reboot
src/tests/lxc-test-criu-check-feature
src/tests/lxc-test-raw-clone
src/tests/lxc-test-share-ns
src/tests/lxc-test-state-server

Signed-off-by: LiFeng <lifeng68 at huawei.com>


  Commit: b5ea184faa9f3edab377ae1dae6544b2d56575e5
      https://github.com/lxc/lxc/commit/b5ea184faa9f3edab377ae1dae6544b2d56575e5
  Author: LiFeng <lifeng68 at huawei.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/start.c

  Log Message:
  -----------
  Fix comments and add check in lxc_poll.

Add check whether handler->conf->console.path is 'none'

Signed-off-by: LiFeng <lifeng68 at huawei.com>


  Commit: 8dae48d74e5b55d57fe6b65837e18cd861e4fc5c
      https://github.com/lxc/lxc/commit/8dae48d74e5b55d57fe6b65837e18cd861e4fc5c
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/lsm/apparmor.c
    M src/lxc/lsm/lsm.c
    M src/lxc/lsm/lsm.h
    M src/lxc/lsm/nop.c
    M src/lxc/lsm/selinux.c

  Log Message:
  -----------
  lsm: non-functional changes

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 4364c487df403aefe8739fd4270b11199fe75888
      https://github.com/lxc/lxc/commit/4364c487df403aefe8739fd4270b11199fe75888
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/attach.c
    M src/lxc/lsm/lsm.c
    M src/lxc/lsm/lsm.h

  Log Message:
  -----------
  lsm: add lsm_process_label_fd_get()

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: ca0650bb1207b6b9c7690647ff1be4f7809ff5e0
      https://github.com/lxc/lxc/commit/ca0650bb1207b6b9c7690647ff1be4f7809ff5e0
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/attach.c
    M src/lxc/lsm/lsm.c
    M src/lxc/lsm/lsm.h

  Log Message:
  -----------
  lsm: add lsm_process_label_set_at()

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 79e6609720b6bea07dfe52371188394745a2e7ca
      https://github.com/lxc/lxc/commit/79e6609720b6bea07dfe52371188394745a2e7ca
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/lsm/apparmor.c
    M src/lxc/utils.h

  Log Message:
  -----------
  apparmor: do not call aa_change_profile()

We can simply write the label ourselves. There's no magic happening.

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 90c199625da0ab943795c2de0aba92f4d495f279
      https://github.com/lxc/lxc/commit/90c199625da0ab943795c2de0aba92f4d495f279
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M configure.ac
    M src/lxc/Makefile.am

  Log Message:
  -----------
  autotools: do not link against libapparmor

Since we write the label directly without going through the AppArmor API it
doesn't make sense to link against it.

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 509862e9316a50d6d8ba69d8b7e7235d096aef9e
      https://github.com/lxc/lxc/commit/509862e9316a50d6d8ba69d8b7e7235d096aef9e
  Author: Marcos Paulo de Souza <marcos.souza.org at gmail.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/network.c
    M src/lxc/network.h

  Log Message:
  -----------
  network.c: Remove ip_forward_set and callers

The last user of ip_forward_set, lxc_ip_forward_on and
lxc_ip_forward_off was in 2009:

commit 92d385229be040cf034ac6efd9405b7bdfe06a3e
Author: Daniel Lezcano <dlezcano at fr.ibm.com>
Date:   Thu Oct 22 15:33:40 2009 +0200

    remove test directory

These functions are not called anymore.

Signed-off-by: Marcos Paulo de Souza <marcos.souza.org at gmail.com>


  Commit: d1d02d493ceca4674479471510c03f9e987a117c
      https://github.com/lxc/lxc/commit/d1d02d493ceca4674479471510c03f9e987a117c
  Author: duguhaotian <duguhaotian at gmail.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/cgroups/cgfsng.c

  Log Message:
  -----------
  [cgfsng] show wrong errno

lxc_cgroup_set_data: h = get_hierarchy(controller);
if h is NULL, now errno is old, it donot set new one.
And then,
cgfsng_setup_limits:

    if (lxc_cgroup_set_data(cg->subsystem, cg->value, d)) {
		if (do_devices && (errno == EACCES ||
			errno == EPERM)) {
			WARN("Error setting %s to %s for %s",
				cg->subsystem, cg->value,
				d->name);
			continue;
		}
		SYSERROR("Error setting %s to %s for
			 %s",
			 cg->subsystem, cg->value,
			 d->name);
		goto out;
	}

SYSERROR will show old errno, make me confused.

Signed-off-by: duguhaotian <duguhaotian at gmail.com>


  Commit: 853752d4731bb3b9c98dd53dc0c3981508ac94d4
      https://github.com/lxc/lxc/commit/853752d4731bb3b9c98dd53dc0c3981508ac94d4
  Author: Tycho Andersen <tycho at tycho.ws>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/utils.c

  Log Message:
  -----------
  better check for lock dir

Consider the case where we're running in a user namespace but in the host's
mount ns with the host's filesystem (something like
lxc-usernsexec ... lxc-execute ...), in this case, we'll be euid 0, but we
can't actually write to /run. Let's improve this locking check to make sure
we can actually write to /run before we decide to actually use it as our
locking dir.

Signed-off-by: Tycho Andersen <tycho at tycho.ws>


  Commit: 283d1d64001b25e6dfe93bd05ee3e99ab318b294
      https://github.com/lxc/lxc/commit/283d1d64001b25e6dfe93bd05ee3e99ab318b294
  Author: Tycho Andersen <tycho at tycho.ws>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/utils.h

  Log Message:
  -----------
  better unprivileged detection

In particular, if we are already in a user namespace we are unprivileged,
and doing things like moving the physical nics back to the host netns won't
work. Let's do the same thing LXD does if euid == 0: inspect
/proc/self/uid_map and see what that says.

Signed-off-by: Tycho Andersen <tycho at tycho.ws>


  Commit: 8ff0ec77a0da087b8f1984db7e3aa409105b83d9
      https://github.com/lxc/lxc/commit/8ff0ec77a0da087b8f1984db7e3aa409105b83d9
  Author: Stéphane Graber <stgraber at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M templates/lxc-debian.in

  Log Message:
  -----------
  debian: Use iproute2 instead of iproute

The package has pretty much always been iproute2 with iproute being an
alias for it, the alias is now gone so we need to use iproute2.

Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>


  Commit: 48a323dfb9a6027b49c52390c4255f4f478a57b3
      https://github.com/lxc/lxc/commit/48a323dfb9a6027b49c52390c4255f4f478a57b3
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/tools/arguments.c

  Log Message:
  -----------
  tools: make "-n" optional

This lets users use the tools with "lxc-* -n <container-name>" or
"lxc-* <container-name>".

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 3f6677005da6cfcdbda742865828a7e9c77a14af
      https://github.com/lxc/lxc/commit/3f6677005da6cfcdbda742865828a7e9c77a14af
  Author: Christian Brauner <christian.brauner at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/lsm/lsm.c
    M src/lxc/lsm/lsm.h
    M src/lxc/lsm/selinux.c

  Log Message:
  -----------
  lsm: do not #ifdefine

Since we stopped linking against AppArmor we can now remove the conditional
compilation.

Signed-off-by: Christian Brauner <christian.brauner at ubuntu.com>


  Commit: 7dc9d017f0b1e15bb557f73aed518973d90063d0
      https://github.com/lxc/lxc/commit/7dc9d017f0b1e15bb557f73aed518973d90063d0
  Author: Stéphane Graber <stgraber at ubuntu.com>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M templates/lxc-debian.in

  Log Message:
  -----------
  debian: We must use iproute on wheezy

Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>


  Commit: 3ba824d28c28c0f3509ac8f2eaf988fb81884ee3
      https://github.com/lxc/lxc/commit/3ba824d28c28c0f3509ac8f2eaf988fb81884ee3
  Author: Tycho Andersen <tycho at tycho.ws>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/lxc_init.c

  Log Message:
  -----------
  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 at tycho.ws>


  Commit: ad9005268f1dd283a0bd874722e793f77698c995
      https://github.com/lxc/lxc/commit/ad9005268f1dd283a0bd874722e793f77698c995
  Author: Tycho Andersen <tycho at tycho.ws>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/start.c

  Log Message:
  -----------
  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 at tycho.ws>


  Commit: 372ecb703f7351c8d9e7a9c41e62fb5915d0ca2c
      https://github.com/lxc/lxc/commit/372ecb703f7351c8d9e7a9c41e62fb5915d0ca2c
  Author: Tycho Andersen <tycho at tycho.ws>
  Date:   2018-02-06 (Tue, 06 Feb 2018)

  Changed paths:
    M src/lxc/lxc_init.c

  Log Message:
  -----------
  lxc.init: ignore SIGHUP

see comment for details.

Signed-off-by: Tycho Andersen <tycho at tycho.ws>


Compare: https://github.com/lxc/lxc/compare/cc66be2a9736...372ecb703f73


More information about the lxc-devel mailing list