nixos-config/machines/chungus/services-forgejo.nix

37 lines
836 B
Nix
Raw Normal View History

2023-07-08 03:15:18 +02:00
{ config, lib, pkgs, ... }:
{
services.nginx = {
enable = true;
statusPage = true;
virtualHosts = {
"git.chungus.private" = {
extraConfig = ''
allow ${config.tinc.private.subnet};
deny all;
'';
locations."/" = {
2024-05-10 23:18:04 +02:00
proxyPass = "http://localhost:${toString config.services.forgejo.settings.server.HTTP_PORT}";
2023-07-08 03:15:18 +02:00
};
};
};
};
2024-05-08 22:07:30 +02:00
services.forgejo = {
2023-07-08 03:15:18 +02:00
enable = true;
2024-05-08 22:07:30 +02:00
stateDir = "/srv/forgejo";
2023-07-08 03:15:18 +02:00
settings = {
2024-05-08 22:07:30 +02:00
DEFAULT.APP_NAME = "git.chungus.private";
2023-07-08 03:15:18 +02:00
server.ROOT_URL = "http://git.chungus.private/";
server.DOMAIN = "git.chungus.private";
service.DISABLE_REGISTRATION = false;
session.COOKIE_SECURE = false;
log.LEVEL = "Warn";
other = {
SHOW_FOOTER_VERSION = false;
};
};
};
}