From 31604069fb6ee77a28ecda0ef99bddd9be923216 Mon Sep 17 00:00:00 2001 From: faukah Date: Thu, 4 Sep 2025 11:56:17 +0200 Subject: [PATCH 1/2] radicle: fix port config, fix enabling --- modules/services/radicle.mod.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/modules/services/radicle.mod.nix b/modules/services/radicle.mod.nix index 6460e7d..4bb3a0a 100644 --- a/modules/services/radicle.mod.nix +++ b/modules/services/radicle.mod.nix @@ -8,8 +8,8 @@ let inherit (lib.lists) singleton; inherit (lib.modules) mkIf; inherit (lib.options) mkEnableOption; - inherit (lib.strings) toString; - port = toString 8776; + inherit (builtins) toString; + port = 8776; domain = "git.faukah.com"; cfg = config.modules.system.services.radicle; @@ -17,7 +17,7 @@ in { options.modules.system.services.radicle.enable = mkEnableOption "radicle"; config.services.radicle = mkIf cfg.enable { - enable = false; + enable = true; checkConfig = true; privateKeyFile = "/etc/ssh/ssh_host_ed25519_key"; publicKey = "/etc/ssh/ssh_host_ed25519_key.pub"; @@ -34,8 +34,8 @@ in settings = { node = { alias = domain; - listen = singleton "[::]:${port}"; - externalAddresses = "${domain}:${port}"; + listen = singleton "[::]:${toString port}"; + externalAddresses = "${domain}:${toString port}"; seedingPolicy = { default = "block"; scope = "all"; From 9eb9240db75ee623e5e154dd37f4c050d3be3401 Mon Sep 17 00:00:00 2001 From: faukah Date: Thu, 4 Sep 2025 12:00:00 +0200 Subject: [PATCH 2/2] radicle: working seed --- modules/services/radicle.mod.nix | 48 ++++++++++++++++++-------------- 1 file changed, 27 insertions(+), 21 deletions(-) diff --git a/modules/services/radicle.mod.nix b/modules/services/radicle.mod.nix index 4bb3a0a..90f9ed2 100644 --- a/modules/services/radicle.mod.nix +++ b/modules/services/radicle.mod.nix @@ -1,7 +1,6 @@ { config, lib, - pkgs, ... }: let @@ -9,36 +8,43 @@ let inherit (lib.modules) mkIf; inherit (lib.options) mkEnableOption; inherit (builtins) toString; - port = 8776; - domain = "git.faukah.com"; + port = 3867; + httpd_port = 3868; + domain = "seed.faukah.com"; cfg = config.modules.system.services.radicle; in { options.modules.system.services.radicle.enable = mkEnableOption "radicle"; - config.services.radicle = mkIf cfg.enable { - enable = true; - checkConfig = true; - privateKeyFile = "/etc/ssh/ssh_host_ed25519_key"; - publicKey = "/etc/ssh/ssh_host_ed25519_key.pub"; - httpd = { + config.services = mkIf cfg.enable { + nginx = { enable = true; - listenPort = port; - listenAddress = "[::]"; - nginx = { + virtualHosts.${domain} = { addSSL = true; enableACME = true; - serverName = domain; + locations."/" = { + proxyPass = "http://localhost:${toString httpd_port}"; + }; }; }; - settings = { - node = { - alias = domain; - listen = singleton "[::]:${toString port}"; - externalAddresses = "${domain}:${toString port}"; - seedingPolicy = { - default = "block"; - scope = "all"; + radicle = { + enable = true; + checkConfig = true; + privateKeyFile = "/etc/ssh/ssh_host_ed25519_key"; + publicKey = "/etc/ssh/ssh_host_ed25519_key.pub"; + httpd = { + enable = true; + listenPort = httpd_port; + }; + settings = { + node = { + alias = domain; + listen = singleton "[::]:${toString port}"; + externalAddresses = singleton "${domain}:${toString port}"; + seedingPolicy = { + default = "block"; + scope = "all"; + }; }; }; };