dms: proper dependencies and port setup

This commit is contained in:
Ingolf Wagner 2020-05-09 01:49:13 +02:00
parent 858f2fb2d9
commit aaa878ff7b
No known key found for this signature in database
GPG key ID: 76BF5F1928B9618B

View file

@ -20,12 +20,17 @@ in {
userlistEnable = true; userlistEnable = true;
localUsers = true; localUsers = true;
writeEnable = true; writeEnable = true;
extraConfig = ''
# additional ports for directory list and stuff
pasv_min_port=4242
pasv_max_port=4243
'';
}; };
networking.firewall.allowedTCPPortRanges = [ networking.firewall.allowedTCPPortRanges = [
{ {
# ftp # ftp: additional ports for directory list and stuff
from = 1024; from = 4242;
to = 65535; to = 4243;
} }
{ {
# ftp # ftp
@ -46,12 +51,12 @@ in {
wantedBy = [ "multi-user.target" ]; wantedBy = [ "multi-user.target" ];
path = [ path = [
(pkgs.python3.withPackages (ps: with ps; [ flask ])) (pkgs.python3.withPackages (ps: with ps; [ flask ]))
pkgs.imagemagick pkgs.imagemagickBig
pkgs.pdfsandwich (pkgs.pdfsandwich.override { imagemagick = pkgs.imagemagickBig; })
pkgs.poppler_utils pkgs.poppler_utils
pkgs.which pkgs.which
pkgs.ghostscript
pkgs.netpbm pkgs.netpbm
pkgs.gawk
]; ];
serviceConfig = { User = "ftp-upload"; }; serviceConfig = { User = "ftp-upload"; };
preStart = '' preStart = ''