diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/bridge.nix | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/modules/bridge.nix b/modules/bridge.nix index 6303266..a1c405a 100644 --- a/modules/bridge.nix +++ b/modules/bridge.nix @@ -29,7 +29,7 @@ with lib; OPENID_ISSUER_URL= "https://auth.orbekk.com/realms/test"; OPENID_CLIENT_ID= "test-client"; OPENID_CLIENT_SECRET= "secret"; - APP_URL = "https://bridge-nightly.orbekk.com"; + APP_URL = "https://bridge.orbekk.com"; DATABASE_URL = "postgres:///bridge_nightly"; RUST_LOG = "info"; }; @@ -37,13 +37,17 @@ with lib; serviceConfig = { User = "bridge_nightly"; Group = "bridge_nightly"; + EnvironmentFile = config.age.secrets.bridge-nighly.path; ExecStart = "/opt/bridge-nightly/profile/bin/server"; }; }; - # "bridge.orbekk.com" = template // { - # locations."/".proxyPass = "http://${bridge_loc.host}:${toString bridge_loc.port}"; - # }; + services.nginx.virtualHosts."bridge.orbekk.com" = { + enableACME = true; + forceSSL = true; + root = "/opt/bridge-nightly/profile"; + locations."/api".proxyPass = "http://localhost:${toString cfg.port}"; + }; services.postgresql = { enable = true; |