Enable Caddy & Gitea
parent
ad2ef22d8c
commit
0996e3953c
|
@ -1,5 +1,7 @@
|
|||
{ ... }: {
|
||||
imports = [
|
||||
./servers/caddy.nix
|
||||
./servers/xpra.nix
|
||||
./servers/gitea.nix
|
||||
];
|
||||
}
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
services.caddy = {
|
||||
enable = true;
|
||||
};
|
||||
# Need 80 & 443 Enabled so Caddy is externally accessible
|
||||
networking.firewall = let
|
||||
ports = [ 80 443 ];
|
||||
in {
|
||||
allowedTCPPorts = ports;
|
||||
allowedUDPPorts = ports;
|
||||
};
|
||||
services.caddy.virtualHosts = lib.mkAfter {
|
||||
"*.ws.kcnhub.com" = {
|
||||
extraConfig = ''
|
||||
error 404
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue