X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=src%2Ftarget.c;h=b8d4a01b6448e37aefd5ae6c44f673097ccc9807;hp=e61255c12311f9adc443f385d0d135ed614f1efb;hb=2fc9784656900c4dc3715db506096ddc23fdd87c;hpb=1f16b4a6c496288aa62dc2ac973f88ca6c801b5d diff --git a/src/target.c b/src/target.c index e61255c12..b8d4a01b6 100644 --- a/src/target.c +++ b/src/target.c @@ -92,6 +92,9 @@ static int target_add_getty_dependencies(Target *t) { if (!unit_has_name(UNIT(t), SPECIAL_GETTY_TARGET)) return 0; + if (detect_container(NULL) > 0) + return 1; + if (read_one_line_file("/sys/class/tty/console/active", &active) >= 0) { const char *tty;