3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/modules/services/logging/klogd.nix
Eelco Dolstra e91d882a94 * Converted modules that were still using the old (concrete syntax)
style of declaring Upstart jobs.  While at it, converted them to the
  current NixOS module style and improved some option descriptions.
  Hopefully I didn't break too much :-)

svn path=/nixos/trunk/; revision=17761
2009-10-12 16:36:19 +00:00

30 lines
502 B
Nix

{ config, pkgs, ... }:
###### implementation
let
klogdCmd = "${pkgs.sysklogd}/sbin/klogd -c 1 -2 -k $(dirname $(readlink -f /var/run/booted-system/kernel))/System.map";
in
{
jobAttrs.klogd =
{ description = "Kernel log daemon";
startOn = "syslogd";
stopOn = "shutdown";
preStart =
''
# !!! this hangs for some reason (it blocks reading from
# /proc/kmsg).
#${klogdCmd} -o
'';
exec = "${klogdCmd} -n";
};
}