mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-19 04:03:56 +00:00
27 lines
449 B
Nix
27 lines
449 B
Nix
|
{sysklogd, writeText, config}:
|
||
|
|
||
|
let
|
||
|
|
||
|
klogdCmd = "${sysklogd}/sbin/klogd -c 1 -2 -k $(dirname $(readlink -f /var/run/booted-system/kernel))/System.map";
|
||
|
|
||
|
in
|
||
|
|
||
|
{
|
||
|
name = "klogd";
|
||
|
|
||
|
job = ''
|
||
|
description "Kernel log daemon"
|
||
|
|
||
|
start on syslogd
|
||
|
stop on shutdown
|
||
|
|
||
|
start script
|
||
|
# !!! this hangs for some reason (it blocks reading from
|
||
|
# /proc/kmsg).
|
||
|
#${klogdCmd} -o
|
||
|
end script
|
||
|
|
||
|
respawn ${klogdCmd} -n
|
||
|
'';
|
||
|
}
|