nextcloud: add legacy redicect

This commit is contained in:
Rouven Seifert 2023-09-06 14:22:56 +02:00
parent d8e3bb4689
commit 8eb6545fc3
Signed by: rouven.seifert
GPG key ID: B95E8FE6B11C4D09

View file

@ -1,6 +1,7 @@
{ config, pkgs, lib, ... }: { config, pkgs, lib, ... }:
let let
domain = "nc.${config.fsr.domain}"; domain = "nc.${config.fsr.domain}";
legacy_domain = "oc.ifsr.de";
in in
{ {
sops.secrets = { sops.secrets = {
@ -35,6 +36,11 @@ in
enableACME = true; enableACME = true;
forceSSL = true; forceSSL = true;
}; };
nginx.virtualHosts.${legacy_domain} = {
enableACME = true;
forceSSL = true;
locations."/".return = "301 https://nc.ifsr.de";
};
}; };
# ensure that postgres is running *before* running the setup # ensure that postgres is running *before* running the setup