diff options
Diffstat (limited to 'modules/services/git-daemon/default.nix')
-rw-r--r-- | modules/services/git-daemon/default.nix | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/modules/services/git-daemon/default.nix b/modules/services/git-daemon/default.nix new file mode 100644 index 0000000..bc06342 --- /dev/null +++ b/modules/services/git-daemon/default.nix @@ -0,0 +1,29 @@ +{ config, lib, ... }: + +with lib; +let + cfg = config.modules.services.gitDaemon; +in +{ + disabledModules = [ + "services/networking/git-daemon.nix" + ]; + + imports = [ + ./_git-daemon-module.nix + ]; + + options.modules.services.gitDaemon = { + enable = mkEnableOption "git daemon"; + }; + + config = mkIf cfg.enable { + services.gitDaemon = { + enable = true; + createUserAndGroup = false; + basePath = "/var/lib/gitolite/repositories"; + }; + + networking.firewall.allowedTCPPorts = [ 9418 ]; + }; +} |