2021-09-10 22:59:40 +02:00
|
|
|
{ hostRegistry, config, pkgs, lib, ... }:
|
2019-03-31 21:46:51 +02:00
|
|
|
|
|
|
|
{
|
2021-02-22 11:45:12 +01:00
|
|
|
imports = [
|
|
|
|
./proxy.nix
|
2021-09-09 18:21:38 +02:00
|
|
|
./stats.nix
|
2021-02-22 11:45:12 +01:00
|
|
|
];
|
2019-03-31 21:46:51 +02:00
|
|
|
|
|
|
|
networking.hostName = "public-access-proxy";
|
2019-06-22 15:05:13 +02:00
|
|
|
networking.useNetworkd = true;
|
2020-05-22 19:07:07 +02:00
|
|
|
networking.interfaces.eth0 = {
|
2021-02-22 11:45:12 +01:00
|
|
|
ipv4.addresses = [{
|
|
|
|
address = "172.20.73.45";
|
|
|
|
prefixLength = 26;
|
|
|
|
}];
|
2020-05-22 19:07:07 +02:00
|
|
|
};
|
|
|
|
networking.defaultGateway = "172.20.73.1";
|
2019-03-31 21:46:51 +02:00
|
|
|
|
2019-04-01 03:15:39 +02:00
|
|
|
my.services.proxy = {
|
2019-03-31 21:46:51 +02:00
|
|
|
enable = true;
|
|
|
|
proxyHosts = [
|
2020-05-22 18:24:37 +02:00
|
|
|
{
|
|
|
|
hostNames = [ "grafana.hq.c3d2.de" ];
|
2021-09-18 00:44:58 +02:00
|
|
|
proxyTo.host = "grafana.serv.zentralwerk.org";
|
2020-05-22 18:24:37 +02:00
|
|
|
}
|
2021-09-04 18:09:05 +02:00
|
|
|
{
|
|
|
|
hostNames = [ "ticker.c3d2.de" ];
|
2021-09-18 00:44:58 +02:00
|
|
|
proxyTo.host = "ticker.serv.zentralwerk.org";
|
2021-09-04 18:09:05 +02:00
|
|
|
}
|
2021-09-05 02:28:48 +02:00
|
|
|
{
|
|
|
|
hostNames = [ "gitea.c3d2.de" ];
|
2021-09-09 16:44:23 +02:00
|
|
|
proxyTo.host = "172.20.73.53";
|
2021-09-05 02:28:48 +02:00
|
|
|
}
|
2021-06-23 21:26:51 +02:00
|
|
|
{
|
2021-09-03 20:49:02 +02:00
|
|
|
hostNames = [ "vps1.nixvita.de" "vps1.codetu.be" "nixvita.de" ];
|
2021-09-09 16:44:23 +02:00
|
|
|
proxyTo.host = "172.20.73.51";
|
2021-09-01 21:26:35 +02:00
|
|
|
}
|
2021-09-10 22:59:40 +02:00
|
|
|
{
|
|
|
|
hostNames = [ "stream.hq.c3d2.de" ];
|
|
|
|
proxyTo.host = hostRegistry.hosts.stream.ip4;
|
|
|
|
}
|
2019-03-31 21:46:51 +02:00
|
|
|
];
|
|
|
|
};
|
|
|
|
|
2021-02-22 11:45:12 +01:00
|
|
|
networking.firewall.allowedTCPPorts = [ 80 443 ];
|
2019-03-31 21:46:51 +02:00
|
|
|
|
2021-09-09 16:44:23 +02:00
|
|
|
system.stateVersion = "18.09";
|
2019-03-31 21:46:51 +02:00
|
|
|
}
|