[systemd-devel] [PATCH] nspawn: require /etc/os-release only for init

Tom Gundersen teg at jklm.no
Mon Feb 10 04:13:04 PST 2014


On Sun, Feb 9, 2014 at 10:49 AM, Vincent Batts <vbatts at redhat.com> wrote:
> /etc/os-release is expected for the case for booting a full system, and
> need not be required for thin container execution.

Applied manually, so please verify that it is as expected. Thanks for the patch!

Cheers,

Tom

>  src/nspawn/nspawn.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/nspawn/nspawn.c b/src/nspawn/nspawn.c
> index f904ebe..cf03a40 100644
> --- a/src/nspawn/nspawn.c
> +++ b/src/nspawn/nspawn.c
> @@ -1200,7 +1200,7 @@ int main(int argc, char *argv[]) {
>                  goto finish;
>          }
>  -        if (path_is_os_tree(arg_directory) <= 0) {
> +        if (arg_boot && path_is_os_tree(arg_directory) <= 0) {
>                  log_error("Directory %s doesn't look like an OS root
> directory (/etc/os-release is missing). Refusing.", arg_directory);
>                  goto finish;
>          }
> --
> 1.8.4
>
>
> _______________________________________________
> systemd-devel mailing list
> systemd-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/systemd-devel
>


More information about the systemd-devel mailing list