dotfiles/nix/hosts/hetznix/services/forgejo.nix

29 lines
574 B
Nix
Raw Normal View History

2025-01-05 15:18:56 +00:00
{ config, ... }:
{
services = {
forgejo = {
enable = false;
2025-01-05 15:18:56 +00:00
settings = {
server = {
DOMAIN = "code.oliverdavies.uk";
HTTP_PORT = 2223;
};
service = {
DISABLE_REGISTRATION = true;
};
};
};
caddy.virtualHosts."${config.services.forgejo.settings.server.DOMAIN}" = {
useACMEHost = "oliverdavies.uk";
extraConfig = "reverse_proxy localhost:${toString config.services.forgejo.settings.server.HTTP_PORT}";
};
openssh.settings.AllowUsers = [ "forgejo" ];
};
}