/nix/store/dlwqlnbaj5vfm9aw20r1yxk8y56lmgif-repo/header.tmpl

Compare commits

..

No commits in common. "9eb9240db75ee623e5e154dd37f4c050d3be3401" and "248985229728484a9efb35789e0d346fec536fd4" have entirely different histories.

View file

@ -1,50 +1,44 @@
{
config,
lib,
pkgs,
...
}:
let
inherit (lib.lists) singleton;
inherit (lib.modules) mkIf;
inherit (lib.options) mkEnableOption;
inherit (builtins) toString;
port = 3867;
httpd_port = 3868;
domain = "seed.faukah.com";
inherit (lib.strings) toString;
port = toString 8776;
domain = "git.faukah.com";
cfg = config.modules.system.services.radicle;
in
{
options.modules.system.services.radicle.enable = mkEnableOption "radicle";
config.services = mkIf cfg.enable {
nginx = {
config.services.radicle = mkIf cfg.enable {
enable = false;
checkConfig = true;
privateKeyFile = "/etc/ssh/ssh_host_ed25519_key";
publicKey = "/etc/ssh/ssh_host_ed25519_key.pub";
httpd = {
enable = true;
virtualHosts.${domain} = {
listenPort = port;
listenAddress = "[::]";
nginx = {
addSSL = true;
enableACME = true;
locations."/" = {
proxyPass = "http://localhost:${toString httpd_port}";
};
serverName = domain;
};
};
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";
};
settings = {
node = {
alias = domain;
listen = singleton "[::]:${port}";
externalAddresses = "${domain}:${port}";
seedingPolicy = {
default = "block";
scope = "all";
};
};
};