diff --git a/hosts/proxy/default.nix b/hosts/proxy/default.nix index 2db90b4..228e23f 100644 --- a/hosts/proxy/default.nix +++ b/hosts/proxy/default.nix @@ -105,23 +105,25 @@ name = "index.html"; text = '' - - - StuRa HTWD Index - - - - - - + + + StuRa HTWD Index + + + +

+ Du hast dich scheinbar verlaufen. Können wir dir hier möglicherweise weiter helfen? +

+ + ''; }; @@ -190,11 +192,13 @@ ${lib.foldlAttrs ( prev: name: value: - prev + "use_backend ${name}_80 if is_${name}\n" + prev + '' + use_backend ${name}_80 if is_${name} + http-request redirect scheme https code 301 if !is_acme is_${name} + '' ) "" forwards} - http-request redirect scheme https code 301 if !is_acme - + default_backend default_backend frontend ssh_jump_alt bind *:2142 @@ -216,6 +220,10 @@ prev + "use_backend ${name}_443 if { req_ssl_sni -i ${value.domain} }\n" ) "" forwards} + backend default_backend + mode http + http-request return status 200 content-type "text/html" file ${indexPage} + backend ssh_srs2 mode tcp timeout server 30m