diff options
-rw-r--r-- | custom/uucp.nix | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/custom/uucp.nix b/custom/uucp.nix index ea6f2eef..d4597260 100644 --- a/custom/uucp.nix +++ b/custom/uucp.nix | |||
@@ -81,9 +81,8 @@ rec { | |||
81 | }; | 81 | }; |
82 | }; | 82 | }; |
83 | 83 | ||
84 | config = { | 84 | config = mkIf config.services.uucp.enable { |
85 | environment.etc."uucp/config" = { | 85 | environment.etc."uucp/config" = { |
86 | enable = config.services.uucp.enable; | ||
87 | text = '' | 86 | text = '' |
88 | spool ${config.services.uucp.spoolDir} | 87 | spool ${config.services.uucp.spoolDir} |
89 | lockdir ${config.services.uucp.lockDir} | 88 | lockdir ${config.services.uucp.lockDir} |
@@ -96,9 +95,9 @@ rec { | |||
96 | ''; | 95 | ''; |
97 | }; | 96 | }; |
98 | 97 | ||
99 | users.users."uucp" = optional config.services.uucp.enable config.services.uucp.sshUser; | 98 | users.users."uucp" = config.services.uucp.sshUser; |
100 | 99 | ||
101 | system.activationScripts."uucp-sshconfig" = optional config.services.uucp.enable '' | 100 | system.activationScripts."uucp-sshconfig" = '' |
102 | mkdir -p ${config.users.users."uucp".home}/.ssh | 101 | mkdir -p ${config.users.users."uucp".home}/.ssh |
103 | cp ${builtins.toFile "ssh-config" config.services.uucp.sshConfig} ${config.users.users."uucp".home}/.ssh/config | 102 | cp ${builtins.toFile "ssh-config" config.services.uucp.sshConfig} ${config.users.users."uucp".home}/.ssh/config |
104 | ''; | 103 | ''; |