mirror of
https://github.com/NixOS/mobile-nixos.git
synced 2025-01-02 04:47:13 +03:00
initrd-logger: enable = false will disable it completely.
This commit is contained in:
parent
0d17ae2279
commit
ca0ef47b71
@ -14,7 +14,7 @@ in
|
||||
config.mobile.boot.stage-1 = {
|
||||
# FIXME : this may not cleanup nicely.
|
||||
# This implementation is naive and simple.
|
||||
init = lib.mkOrder AFTER_SWITCH_ROOT_INIT ''
|
||||
init = lib.mkIf cfg.enable (lib.mkOrder AFTER_SWITCH_ROOT_INIT ''
|
||||
_stop_logger() {
|
||||
local i=0 pid
|
||||
# re-attach to /dev/console
|
||||
@ -22,6 +22,6 @@ in
|
||||
# Kill the process
|
||||
kill $(cat ${pidfile})
|
||||
}
|
||||
'';
|
||||
'');
|
||||
};
|
||||
}
|
||||
|
@ -46,7 +46,7 @@ in
|
||||
|
||||
# FIXME : this may not cleanup nicely.
|
||||
# This implementation is naive and simple.
|
||||
init = lib.mkOrder AFTER_DEVICE_INIT ''
|
||||
init = lib.mkIf cfg.enable (lib.mkOrder AFTER_DEVICE_INIT ''
|
||||
_logger() {
|
||||
# Setup all redirections
|
||||
${builtins.concatStringsSep "\n" (
|
||||
@ -73,6 +73,6 @@ in
|
||||
_logger < ${pipe} > /dev/console 2&1 &
|
||||
printf %s $! > ${pidfile}
|
||||
exec >${pipe} 2>&1
|
||||
'';
|
||||
'');
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user