vsftpd service: add extraConfig option, set anon_root (#20069)
This commit includes two changes: 1. A new `extraConfig` option to allow administrators to set any vsftpd configuration option that isn't directly supported by this derivation. 2. Correctly set the `anon_root` vsftpd option to `anonymousUserHome`
This commit is contained in:
parent
7fd38dc8b3
commit
d19967bf48
|
@ -100,6 +100,10 @@ let
|
|||
seccomp_sandbox=NO
|
||||
''}
|
||||
anon_umask=${cfg.anonymousUmask}
|
||||
${optionalString cfg.anonymousUser ''
|
||||
anon_root=${cfg.anonymousUserHome}
|
||||
''}
|
||||
${cfg.extraConfig}
|
||||
'';
|
||||
|
||||
in
|
||||
|
@ -163,6 +167,13 @@ in
|
|||
description = "Anonymous write umask.";
|
||||
};
|
||||
|
||||
extraConfig = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
example = "ftpd_banner=Hello";
|
||||
description = "Extra configuration to add at the bottom of the generated configuration file.";
|
||||
};
|
||||
|
||||
} // (listToAttrs (catAttrs "nixosOption" optionDescription));
|
||||
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue