nix/host/x86_64-linux/home/nginx/Forgejo.nix

17 lines
369 B
Nix
Raw Normal View History

{ config, ... }:
let
cfg = config.const.host.nginx;
in
2024-12-02 21:12:45 +03:00
{
"git.${cfg.domain}" = {
inherit (cfg) sslCertificate sslCertificateKey extraConfig;
locations = {
"~ ^/(admin|api|user)" = {
extraConfig = cfg.allowLocal;
proxyPass = "http://[::1]:3000$request_uri";
};
"/".proxyPass = "http://[::1]:3000$request_uri";
};
};
2024-12-02 21:12:45 +03:00
}