mirror of
https://github.com/clearlinux/systemd-stable.git
synced 2026-09-06 13:41:31 +00:00
main: explain our /etc empty check a bit in a comment
(cherry picked from commit 3408ba015a)
This commit is contained in:
committed by
Zbigniew Jędrzejewski-Szmek
parent
a71b7b7e52
commit
a821499e67
@@ -1543,6 +1543,14 @@ int main(int argc, char *argv[]) {
|
||||
if (in_initrd())
|
||||
log_info("Running in initial RAM disk.");
|
||||
|
||||
/* Let's check whether /etc is already populated. We
|
||||
* don't actually really check for that, but use
|
||||
* /etc/machine-id as flag file. This allows container
|
||||
* managers and installers to provision a couple of
|
||||
* files already. If the container manager wants to
|
||||
* provision the machine ID itself it should pass
|
||||
* $container_uuid to PID 1.*/
|
||||
|
||||
empty_etc = access("/etc/machine-id", F_OK) < 0;
|
||||
if (empty_etc)
|
||||
log_info("Running with unpopulated /etc.");
|
||||
|
||||
Reference in New Issue
Block a user