nspawn: only warn about audit when booting the container

The audit subsystem isn't relevant when nspawn is only being used as a
chroot.
This commit is contained in:
Dave Reisner 2013-05-10 08:59:00 -04:00
parent ddeb424198
commit c2384970ff

View file

@ -1296,7 +1296,7 @@ int main(int argc, char *argv[]) {
goto finish;
}
if (audit_enabled()) {
if (arg_boot && audit_enabled()) {
log_warning("The kernel auditing subsystem is known to be incompatible with containers.\n"
"Please make sure to turn off auditing with 'audit=0' on the kernel command\n"
"line before using systemd-nspawn. Sleeping for 5s...\n");