diff options
| author | Franck Cuny <franck@fcuny.net> | 2025-11-22 09:02:43 -0800 |
|---|---|---|
| committer | Franck Cuny <franck@fcuny.net> | 2025-11-22 09:02:43 -0800 |
| commit | 7d27388cd47c8cd849054547d2ad55ea5f41f67d (patch) | |
| tree | 8f8663fb1f4c878d90a274271f2c277c36439399 /machines | |
| parent | wireguard configuration for argonath (diff) | |
| download | infra-7d27388cd47c8cd849054547d2ad55ea5f41f67d.tar.gz | |
configure the reverse proxy on argonath
Diffstat (limited to 'machines')
| -rw-r--r-- | machines/nixos/x86_64-linux/argonath.nix | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/machines/nixos/x86_64-linux/argonath.nix b/machines/nixos/x86_64-linux/argonath.nix index 14b698a..af70040 100644 --- a/machines/nixos/x86_64-linux/argonath.nix +++ b/machines/nixos/x86_64-linux/argonath.nix @@ -6,6 +6,7 @@ }: { imports = [ + ../../../profiles/acme.nix ../../../profiles/cgroups.nix ../../../profiles/defaults.nix ../../../profiles/hardware/do-droplet.nix @@ -41,6 +42,37 @@ networking.firewall.trustedInterfaces = [ "wg0" ]; networking.firewall.allowedUDPPorts = [ 51871 ]; + networking.firewall.allowedTCPPorts = [ + 80 + 443 + ]; + + services.nginx = { + enable = true; + recommendedProxySettings = true; + recommendedGzipSettings = true; + recommendedOptimisation = true; + recommendedTlsSettings = true; + virtualHosts = { + "code.fcuny.net" = { + enableACME = true; + acmeRoot = null; + forceSSL = true; + locations."/" = { + proxyPass = "http://10.100.0.60"; + }; + }; + "fcuny.net" = { + enableACME = true; + acmeRoot = null; + forceSSL = true; + locations."/" = { + proxyPass = "http://10.100.0.60:8070"; + }; + }; + }; + }; + system.stateVersion = "25.05"; # Did you read the comment? home-manager = { |
