|
659 | 659 | }));
|
660 | 660 | };
|
661 | 661 |
|
| 662 | + systemd.user.paths = mkOption { |
| 663 | + default = {}; |
| 664 | + type = with types; attrsOf (submodule [ { options = pathOptions; } unitConfig ]); |
| 665 | + description = "Definition of systemd per-user path units."; |
| 666 | + }; |
| 667 | + |
662 | 668 | systemd.user.services = mkOption {
|
663 | 669 | default = {};
|
664 | 670 | type = with types; attrsOf (submodule [ { options = serviceOptions; } unitConfig serviceConfig ] );
|
665 | 671 | description = "Definition of systemd per-user service units.";
|
666 | 672 | };
|
667 | 673 |
|
668 |
| - systemd.user.timers = mkOption { |
| 674 | + systemd.user.slices = mkOption { |
669 | 675 | default = {};
|
670 |
| - type = with types; attrsOf (submodule [ { options = timerOptions; } unitConfig ] ); |
671 |
| - description = "Definition of systemd per-user timer units."; |
| 676 | + type = with types; attrsOf (submodule [ { options = sliceOptions; } unitConfig ] ); |
| 677 | + description = "Definition of systemd per-user slice units."; |
672 | 678 | };
|
673 | 679 |
|
674 | 680 | systemd.user.sockets = mkOption {
|
|
683 | 689 | description = "Definition of systemd per-user target units.";
|
684 | 690 | };
|
685 | 691 |
|
| 692 | + systemd.user.timers = mkOption { |
| 693 | + default = {}; |
| 694 | + type = with types; attrsOf (submodule [ { options = timerOptions; } unitConfig ] ); |
| 695 | + description = "Definition of systemd per-user timer units."; |
| 696 | + }; |
| 697 | + |
686 | 698 | systemd.additionalUpstreamSystemUnits = mkOption {
|
687 | 699 | default = [ ];
|
688 | 700 | type = types.listOf types.str;
|
|
799 | 811 | };
|
800 | 812 |
|
801 | 813 | systemd.units =
|
802 |
| - mapAttrs' (n: v: nameValuePair "${n}.target" (targetToUnit n v)) cfg.targets |
| 814 | + mapAttrs' (n: v: nameValuePair "${n}.path" (pathToUnit n v)) cfg.paths |
803 | 815 | // mapAttrs' (n: v: nameValuePair "${n}.service" (serviceToUnit n v)) cfg.services
|
804 |
| - // mapAttrs' (n: v: nameValuePair "${n}.socket" (socketToUnit n v)) cfg.sockets |
805 |
| - // mapAttrs' (n: v: nameValuePair "${n}.timer" (timerToUnit n v)) cfg.timers |
806 |
| - // mapAttrs' (n: v: nameValuePair "${n}.path" (pathToUnit n v)) cfg.paths |
807 |
| - // mapAttrs' (n: v: nameValuePair "${n}.slice" (sliceToUnit n v)) cfg.slices |
| 816 | + // mapAttrs' (n: v: nameValuePair "${n}.slice" (sliceToUnit n v)) cfg.slices |
| 817 | + // mapAttrs' (n: v: nameValuePair "${n}.socket" (socketToUnit n v)) cfg.sockets |
| 818 | + // mapAttrs' (n: v: nameValuePair "${n}.target" (targetToUnit n v)) cfg.targets |
| 819 | + // mapAttrs' (n: v: nameValuePair "${n}.timer" (timerToUnit n v)) cfg.timers |
808 | 820 | // listToAttrs (map
|
809 | 821 | (v: let n = escapeSystemdPath v.where;
|
810 | 822 | in nameValuePair "${n}.mount" (mountToUnit n v)) cfg.mounts)
|
|
813 | 825 | in nameValuePair "${n}.automount" (automountToUnit n v)) cfg.automounts);
|
814 | 826 |
|
815 | 827 | systemd.user.units =
|
816 |
| - mapAttrs' (n: v: nameValuePair "${n}.service" (serviceToUnit n v)) cfg.user.services |
| 828 | + mapAttrs' (n: v: nameValuePair "${n}.path" (pathToUnit n v)) cfg.user.paths |
| 829 | + // mapAttrs' (n: v: nameValuePair "${n}.service" (serviceToUnit n v)) cfg.user.services |
| 830 | + // mapAttrs' (n: v: nameValuePair "${n}.slice" (sliceToUnit n v)) cfg.user.slices |
817 | 831 | // mapAttrs' (n: v: nameValuePair "${n}.socket" (socketToUnit n v)) cfg.user.sockets
|
818 | 832 | // mapAttrs' (n: v: nameValuePair "${n}.target" (targetToUnit n v)) cfg.user.targets
|
819 | 833 | // mapAttrs' (n: v: nameValuePair "${n}.timer" (timerToUnit n v)) cfg.user.timers;
|
|
0 commit comments