Add a few more bypass environment variables

When we're building ParticleOS images, we don't want the package
manager (or mkosi) to run systemd-sysusers, systemd-tmpfiles or
systemctl preset so let's add a few more bypass environment
variables that we can set to have execution of these skipped like
we already have $SYSTEMD_HWDB_UPDATE_BYPASS and $KERNEL_INSTALL_BYPASS.
This commit is contained in:
Daan De Meyer
2025-03-01 16:22:53 +01:00
parent 38701809a8
commit daa2547e31
9 changed files with 54 additions and 20 deletions
+4
View File
@@ -71,6 +71,7 @@
#include "terminal-util.h"
#include "umask-util.h"
#include "user-util.h"
#include "verbs.h"
#include "virt.h"
#include "xattr-util.h"
@@ -4618,6 +4619,9 @@ static int run(int argc, char *argv[]) {
if (arg_cat_flags != CAT_CONFIG_OFF)
return cat_config(config_dirs, argv + optind);
if (should_bypass("SYSTEMD_TMPFILES"))
return 0;
umask(0022);
r = mac_init();