c4fb0432ae
GitOrigin-RevId: 3fc1143a04da49a92c3663813c6a0c1e8ccd477f
27 lines
545 B
Nix
27 lines
545 B
Nix
{ config, ... }:
|
|
|
|
{
|
|
imports = [
|
|
./base.nix
|
|
];
|
|
|
|
config = {
|
|
services.nginx.virtualHosts.cgit = {
|
|
serverName = "code.tvl.fyi";
|
|
enableACME = true;
|
|
forceSSL = true;
|
|
|
|
extraConfig = ''
|
|
# Static assets must always hit the root.
|
|
location ~ ^/(favicon\.ico|cgit\.(css|png))$ {
|
|
proxy_pass http://localhost:2448;
|
|
}
|
|
|
|
# Everything else hits the depot directly.
|
|
location / {
|
|
proxy_pass http://localhost:2448/cgit.cgi/depot/;
|
|
}
|
|
'';
|
|
};
|
|
};
|
|
}
|