2 { config, lib, pkgs, ... }:
8 cfg = config.services.svnserve;
23 description = "Whether to enable svnserve to serve Subversion repositories through the SVN protocol.";
26 svnBaseDir = mkOption {
29 description = "Base directory from which Subversion repositories are accessed.";
38 config = mkIf cfg.enable {
39 systemd.services.svnserve = {
40 after = [ "network.target" ];
41 wantedBy = [ "multi-user.target" ];
42 preStart = "mkdir -p ${cfg.svnBaseDir}";
43 script = "${pkgs.subversion.out}/bin/svnserve -r ${cfg.svnBaseDir} -d --foreground --pid-file=/run/svnserve.pid";