diff options
Diffstat (limited to 'Biz/Cloud')
-rw-r--r-- | Biz/Cloud/Chat.nix | 6 | ||||
-rw-r--r-- | Biz/Cloud/Git.nix | 1 | ||||
-rw-r--r-- | Biz/Cloud/Gmnisrv.nix | 10 | ||||
-rw-r--r-- | Biz/Cloud/Web.nix | 3 |
4 files changed, 13 insertions, 7 deletions
diff --git a/Biz/Cloud/Chat.nix b/Biz/Cloud/Chat.nix index 0c29f3f..be856d8 100644 --- a/Biz/Cloud/Chat.nix +++ b/Biz/Cloud/Chat.nix @@ -22,9 +22,9 @@ in { # services.matrix-synapse = { enable = false; - server_name = config.networking.domain; - registration_shared_secret = "AkGRWSQLga3RoKRFnHhKoeCEIeZzu31y4TRzMRkMyRbBnETkVTSxilf24qySLzQn"; - listeners = [ + settings.server_name = config.networking.domain; + #registration_shared_secret = "AkGRWSQLga3RoKRFnHhKoeCEIeZzu31y4TRzMRkMyRbBnETkVTSxilf24qySLzQn"; + settings.listeners = [ { port = matrix_port; bind_address = "::1"; diff --git a/Biz/Cloud/Git.nix b/Biz/Cloud/Git.nix index a75fa82..fadf2aa 100644 --- a/Biz/Cloud/Git.nix +++ b/Biz/Cloud/Git.nix @@ -59,6 +59,7 @@ in { # git group users.users = { gitDaemon = { + group = "gitDaemon"; isSystemUser = true; description = "Git daemon user"; extraGroups = [ "git" ]; diff --git a/Biz/Cloud/Gmnisrv.nix b/Biz/Cloud/Gmnisrv.nix index c60d271..2f7672b 100644 --- a/Biz/Cloud/Gmnisrv.nix +++ b/Biz/Cloud/Gmnisrv.nix @@ -10,13 +10,16 @@ in { meta.maintainers = [ lib.maintainers.bsima ]; options.services.gmnisrv = { enable = lib.mkEnableOption "Enable the gmnisrv service"; + listen = lib.mkOption { + description = "Addresses and ports on which to listen."; + default = lib.mkDefault "0.0.0.0:1965 [::]:1965"; + }; settings = lib.mkOption { # type = cfgFormat.type; description = '' Configuration for gmnisrv. See gmnisrv.ini(5) for supported settings. ''; default = { - "listen" = lib.mkDefault "0.0.0.0:1965 [::]:1965"; ":tls" = { "store" = lib.mkDefault "${cfg.dataDir}/certs"; }; @@ -33,7 +36,10 @@ in { description = "gmnisrv service"; wantedBy = [ "multi-user.target" ]; after = [ "network-online.target" ]; - script = "${pkgs.gmnisrv}/bin/gmnisrv -C ${lib.generators.toINI {} cfg.settings}"; + script = let ini = lib.generators.toINIWithGlobalSection {} { + globalSection = {"listen" = cfg.listen;}; + sections = cfg.settings; + }; in "${pkgs.gmnisrv}/bin/gmnisrv -C ${ini}"; }; }; } diff --git a/Biz/Cloud/Web.nix b/Biz/Cloud/Web.nix index e0b9a95..c699b1b 100644 --- a/Biz/Cloud/Web.nix +++ b/Biz/Cloud/Web.nix @@ -37,10 +37,9 @@ in }; }; gmnisrv = { - package = pkgs.gmnisrv; enable = true; + listen = "0.0.0.0:${toString ports.gemini} [::]:${toString ports.gemini}"; settings = { - listen = "0.0.0.0:${toString ports.gemini} [::]:${toString ports.gemini}"; ":tls" = { store = "/var/lib/gmnisrv"; }; "bsima.me" = { "root" = "/var/web/ben"; |