diff options
author | Lennart Poettering <lennart@poettering.net> | 2022-08-25 17:32:28 +0200 |
---|---|---|
committer | Luca Boccassi <luca.boccassi@gmail.com> | 2022-08-25 22:27:26 +0100 |
commit | abd6faae80fa87ecc24a000447b86fc32499809d (patch) | |
tree | 908abf14e1e4b881b41cec96098acfc733f59ff3 /src/journal | |
parent | bf07a1251615629d4fc663b773ef1daf9aad77af (diff) | |
download | systemd-abd6faae80fa87ecc24a000447b86fc32499809d.tar.gz |
journal: rename special journal field _SYSTEM_CONTEXT= → _RUNTIME_SCOPE=
Previously the field "_SYSTEM_CONTEXT" knew he values "initrd" + "main". Let's change
this to "_RUNTIME_SCOPE" and "initrd" + "system".
Why? The sysext logic has a very similar concept of "scopes", declaring
whether a sysext image is intended for the initrd or the main system.
Let's thus use the same naming for both.
sysext's extension-release files hence know SYSEXT_SCOPE=initrd|system,
and the journal messages know _RUNTIME_SCOPE=initrd|system, which makes
this reasonably systematic.
Follow-up for: cae8edd93ca2ef90c41cb9b6322b6908d12947b5
(This is not an API break, since no version with this commit has ever
been released.)
Diffstat (limited to 'src/journal')
-rw-r--r-- | src/journal/journald-server.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/journal/journald-server.c b/src/journal/journald-server.c index 49cede6892..3992d15664 100644 --- a/src/journal/journald-server.c +++ b/src/journal/journald-server.c @@ -1035,11 +1035,7 @@ static void dispatch_message_real( if (!isempty(s->namespace_field)) iovec[n++] = IOVEC_MAKE_STRING(s->namespace_field); - if (in_initrd()) - iovec[n++] = IOVEC_MAKE_STRING("_SYSTEM_CONTEXT=initrd"); - else - iovec[n++] = IOVEC_MAKE_STRING("_SYSTEM_CONTEXT=main"); - + iovec[n++] = in_initrd() ? IOVEC_MAKE_STRING("_RUNTIME_SCOPE=initrd") : IOVEC_MAKE_STRING("_RUNTIME_SCOPE=system"); assert(n <= m); if (s->split_mode == SPLIT_UID && c && uid_is_valid(c->uid)) |