nixos/apparmor: order before sysinit.target

Otherwise, profiles may be loaded way too late in the init process.
This commit is contained in:
Joachim Fasting 2019-04-28 14:22:19 +02:00
parent dfd8f84aef
commit f824dad19a
No known key found for this signature in database
GPG Key ID: 5C204DF675C90294

View File

@ -33,7 +33,12 @@ in
paths = concatMapStrings (s: " -I ${s}/etc/apparmor.d")
([ pkgs.apparmor-profiles ] ++ cfg.packages);
in {
wantedBy = [ "local-fs.target" ];
after = [ "local-fs.target" ];
before = [ "sysinit.target" ];
wantedBy = [ "multi-user.target" ];
unitConfig = {
DefaultDependencies = "no";
};
serviceConfig = {
Type = "oneshot";
RemainAfterExit = "yes";