ingress-proxy: refactor statics
This commit is contained in:
parent
7bc8e2aa32
commit
ff90426695
1 changed files with 21 additions and 15 deletions
|
@ -23,7 +23,21 @@ in {
|
|||
hsb.servers."${tsHost "happystaticbuzz" 8080}" = {};
|
||||
};
|
||||
|
||||
virtualHosts = {
|
||||
virtualHosts = let
|
||||
static = { src ? null, url, ref, aliases ? [] }: {
|
||||
http2 = true;
|
||||
http3 = true;
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
|
||||
serverAliases = aliases;
|
||||
|
||||
root = pkgs.stdenvNoCC.mkDerivation {
|
||||
src = src ? builtins.fetchGit { inherit url ref; };
|
||||
installPhase = "cp -r $src $out";
|
||||
};
|
||||
};
|
||||
in {
|
||||
# Matrix (main)
|
||||
"mx.sapphic.engineer" = {
|
||||
forceSSL = true;
|
||||
|
@ -73,21 +87,13 @@ in {
|
|||
'';
|
||||
};
|
||||
|
||||
"mekanoe.com" = {
|
||||
http2 = true;
|
||||
http3 = true;
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
|
||||
root = pkgs.stdenvNoCC.mkDerivation {
|
||||
name = "mekanoe.com";
|
||||
src = builtins.fetchGit {
|
||||
"mekanoe.com" = static {
|
||||
url = "https://codeberg.org/noe/personal-site.git";
|
||||
ref = "main";
|
||||
rev = "8601d3a426bc07c715f265b2132b384c21397533";
|
||||
};
|
||||
installPhase = "cp -r $src $out";
|
||||
};
|
||||
|
||||
"oc.mekanoe.com" = static {
|
||||
src = pkgs.writeText "oc.mekanoe.com" "down";
|
||||
};
|
||||
|
||||
# Generic store for /.well-known/ paths.
|
||||
|
|
Loading…
Add table
Reference in a new issue