feat(vps): add caddy reverse proxy for vaultwarden at /vaultwarden/

This commit is contained in:
lightly-toasted 2025-10-02 21:41:42 +09:00
parent 362e2f99b1
commit 1f28e2853d
3 changed files with 9 additions and 0 deletions

View file

@ -1,3 +1,5 @@
{ pkgs, ... }:
{
services.caddy = {
enable = true;
@ -6,5 +8,10 @@
virtualHosts."i.toast.name".extraConfig = ''
reverse_proxy http://127.0.0.1:3000
'';
# vaultwarden
virtualHosts."vps.curl-pence.ts.net".extraConfig = ''
reverse_proxy /vaultwarden/* http://127.0.0.1:8222
'';
};
}

View file

@ -7,5 +7,6 @@
enable = true;
authKeyFile = config.sops.secrets."tailscale/authkey".path;
useRoutingFeatures = "both";
permitCertUid = "caddy";
};
}

View file

@ -4,6 +4,7 @@
config = {
ROCKET_ADDRESS = "127.0.0.1";
ROCKET_PORT = 8222;
DOMAIN = "https://vps.curl-pence.ts.net/vaultwarden";
};
};
}