diff --git a/config/hosts/public-web-static/spaceapid-config/ccchh-response.json b/config/hosts/public-web-static/spaceapid-config/ccchh-response.json index 3127d20..47d11aa 100644 --- a/config/hosts/public-web-static/spaceapid-config/ccchh-response.json +++ b/config/hosts/public-web-static/spaceapid-config/ccchh-response.json @@ -33,7 +33,7 @@ "links": [ { "name": "Wiki", - "url": "https://wiki.hamburg.ccc.de" + "url": "https://wiki.ccchh.net" }, { "name": "Git (Forgejo)", diff --git a/config/hosts/public-web-static/virtualHosts/c3cat.de.nix b/config/hosts/public-web-static/virtualHosts/c3cat.de.nix index f1ad527..9533e93 100644 --- a/config/hosts/public-web-static/virtualHosts/c3cat.de.nix +++ b/config/hosts/public-web-static/virtualHosts/c3cat.de.nix @@ -28,7 +28,7 @@ ]; locations."/" = { - return = "302 https://wiki.hamburg.ccc.de/club:c3cat:start"; + return = "302 https://wiki.ccchh.net/club:c3cat:start"; }; extraConfig = '' diff --git a/config/hosts/public-web-static/virtualHosts/default.nix b/config/hosts/public-web-static/virtualHosts/default.nix index e22165f..5036faf 100644 --- a/config/hosts/public-web-static/virtualHosts/default.nix +++ b/config/hosts/public-web-static/virtualHosts/default.nix @@ -5,9 +5,7 @@ ./branding-resources.hamburg.ccc.de.nix ./c3cat.de.nix ./element.hamburg.ccc.de.nix - ./hamburg.ccc.de.nix + ./next.hamburg.ccc.de.nix ./spaceapi.hamburg.ccc.de.nix - ./staging.hamburg.ccc.de.nix - ./www.hamburg.ccc.de.nix ]; } diff --git a/config/hosts/public-web-static/virtualHosts/element-web-config/config.json b/config/hosts/public-web-static/virtualHosts/element-web-config/config.json index 19cfdf0..393c215 100644 --- a/config/hosts/public-web-static/virtualHosts/element-web-config/config.json +++ b/config/hosts/public-web-static/virtualHosts/element-web-config/config.json @@ -49,7 +49,7 @@ "auth_header_logo_url": "https://branding-resources.hamburg.ccc.de/logo/ccchh-logo-no-background.png", "auth_footer_links": [ { "text": "Website", "url": "https://hamburg.ccc.de/" }, - { "text": "Wiki", "url": "https://wiki.hamburg.ccc.de/" }, + { "text": "Wiki", "url": "https://wiki.ccchh.net/" }, { "text": "Status", "url": "https://status.ccchh.net/status/main" } ] } diff --git a/config/hosts/public-web-static/virtualHosts/hamburg.ccc.de.nix b/config/hosts/public-web-static/virtualHosts/hamburg.ccc.de.nix deleted file mode 100644 index a318fec..0000000 --- a/config/hosts/public-web-static/virtualHosts/hamburg.ccc.de.nix +++ /dev/null @@ -1,87 +0,0 @@ -{ pkgs, ... }: - -{ - services.nginx.virtualHosts = { - "acme-hamburg.ccc.de" = { - enableACME = true; - serverName = "hamburg.ccc.de"; - - listen = [ - { - addr = "0.0.0.0"; - port = 31820; - } - ]; - }; - - "hamburg.ccc.de" = { - forceSSL = true; - useACMEHost = "hamburg.ccc.de"; - - listen = [ - { - addr = "0.0.0.0"; - port = 8443; - ssl = true; - proxyProtocol = true; - } - ]; - - root = "/var/www/hamburg.ccc.de/"; - - # Redirect the old spaceapi endpoint to the new one. - locations."/dooris/status.json" = { - return = "302 https://spaceapi.hamburg.ccc.de/"; - }; - - # Redirect pages starting with 4 digits for redirecting the old blog - # article URLs. - # We want to redirect /yyyy/mm/dd/slug to /blog/yyyy/mm/dd/slug, but we - # just match the first 4 digits for simplicity. - locations."~ \"^/[\\d]{4}\"" = { - return = "302 https://$host/blog$request_uri"; - }; - - # Redirect pages, which previously lived on the old website, to their - # successors in the wiki. - locations."/club/satzung" = { - return = "302 https://wiki.hamburg.ccc.de/verein:offizielles:satzung"; - }; - locations."/club/hausordnung" = { - return = "302 https://wiki.hamburg.ccc.de/verein:offizielles:hausordnung"; - }; - locations."/club/vertrauenspersonen" = { - return = "302 https://wiki.hamburg.ccc.de/verein:offizielles:vertrauenspersonen"; - }; - locations."/club/beitragsordnung" = { - return = "302 https://wiki.hamburg.ccc.de/verein:offizielles:beitragsordnung"; - }; - locations."/club/mitgliedschaft" = { - return = "302 https://wiki.hamburg.ccc.de/verein:offizielles:foemi-formular"; - }; - locations."/club/geschichte" = { - return = "302 https://wiki.hamburg.ccc.de/club:geschichte"; - }; - - extraConfig = '' - # Make use of the ngx_http_realip_module to set the $remote_addr and - # $remote_port to the client address and client port, when using proxy - # protocol. - # First set our proxy protocol proxy as trusted. - set_real_ip_from 172.31.17.140; - # Then tell the realip_module to get the addreses from the proxy protocol - # header. - real_ip_header proxy_protocol; - ''; - }; - }; - - users.users.ccchh-website-deploy = { - isNormalUser = true; - group = "ccchh-website-deploy"; - openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILX847OMjYC+he1nbV37rrdCQVGINFY43CwLjZDM9iyb ccchh website deployment key" - ]; - }; - users.groups.ccchh-website-deploy = { }; -} diff --git a/config/hosts/public-web-static/virtualHosts/staging.hamburg.ccc.de.nix b/config/hosts/public-web-static/virtualHosts/next.hamburg.ccc.de.nix similarity index 69% rename from config/hosts/public-web-static/virtualHosts/staging.hamburg.ccc.de.nix rename to config/hosts/public-web-static/virtualHosts/next.hamburg.ccc.de.nix index a36a099..a0dff81 100644 --- a/config/hosts/public-web-static/virtualHosts/staging.hamburg.ccc.de.nix +++ b/config/hosts/public-web-static/virtualHosts/next.hamburg.ccc.de.nix @@ -2,9 +2,9 @@ { services.nginx.virtualHosts = { - "acme-staging.hamburg.ccc.de" = { + "acme-next.hamburg.ccc.de" = { enableACME = true; - serverName = "staging.hamburg.ccc.de"; + serverName = "next.hamburg.ccc.de"; listen = [ { @@ -14,9 +14,9 @@ ]; }; - "staging.hamburg.ccc.de" = { + "next.hamburg.ccc.de" = { forceSSL = true; - useACMEHost = "staging.hamburg.ccc.de"; + useACMEHost = "next.hamburg.ccc.de"; listen = [ { @@ -27,13 +27,7 @@ } ]; - root = "/var/www/staging.hamburg.ccc.de/"; - - # Disallow *, since this is staging and doesn't need to be in any search - # results. - locations."/robots.txt" = { - return = "200 \"User-agent: *\\nDisallow: *\\n\""; - }; + root = "/var/www/next.hamburg.ccc.de/"; extraConfig = '' # Make use of the ngx_http_realip_module to set the $remote_addr and @@ -52,7 +46,7 @@ isNormalUser = true; group = "ccchh-website-deploy"; openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILX847OMjYC+he1nbV37rrdCQVGINFY43CwLjZDM9iyb ccchh website deployment key" + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILX847OMjYC+he1nbV37rrdCQVGINFY43CwLjZDM9iyb next.hamburg.ccc.de deployment key" ]; }; users.groups.ccchh-website-deploy = { }; diff --git a/config/hosts/public-web-static/virtualHosts/www.hamburg.ccc.de.nix b/config/hosts/public-web-static/virtualHosts/www.hamburg.ccc.de.nix deleted file mode 100644 index a29fbd2..0000000 --- a/config/hosts/public-web-static/virtualHosts/www.hamburg.ccc.de.nix +++ /dev/null @@ -1,46 +0,0 @@ -{ pkgs, ... }: - -{ - services.nginx.virtualHosts = { - "acme-www.hamburg.ccc.de" = { - enableACME = true; - serverName = "www.hamburg.ccc.de"; - - listen = [ - { - addr = "0.0.0.0"; - port = 31820; - } - ]; - }; - - "www.hamburg.ccc.de" = { - forceSSL = true; - useACMEHost = "www.hamburg.ccc.de"; - - listen = [ - { - addr = "0.0.0.0"; - port = 8443; - ssl = true; - proxyProtocol = true; - } - ]; - - locations."/" = { - return = "302 https://hamburg.ccc.de$request_uri"; - }; - - extraConfig = '' - # Make use of the ngx_http_realip_module to set the $remote_addr and - # $remote_port to the client address and client port, when using proxy - # protocol. - # First set our proxy protocol proxy as trusted. - set_real_ip_from 172.31.17.140; - # Then tell the realip_module to get the addreses from the proxy protocol - # header. - real_ip_header proxy_protocol; - ''; - }; - }; -}