From 54116aafeaf2fb7d5cdf13ede8e183d8b5524e9f Mon Sep 17 00:00:00 2001 From: Max Date: Sat, 21 May 2022 13:56:56 +0200 Subject: [PATCH] services/websites: host ky.rip --- hosts/VEGAS/services/websites/default.nix | 10 ++++++++-- hosts/VEGAS/services/websites/extra-sites.nix | 10 ++++++++++ 2 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 hosts/VEGAS/services/websites/extra-sites.nix diff --git a/hosts/VEGAS/services/websites/default.nix b/hosts/VEGAS/services/websites/default.nix index 2758578..7b71772 100644 --- a/hosts/VEGAS/services/websites/default.nix +++ b/hosts/VEGAS/services/websites/default.nix @@ -1,5 +1,11 @@ { config, lib, tools, ... }: -{ - services.nginx.virtualHosts = tools.nginx.mappers.mapSubdomains (import ./websites.nix { tools = tools.nginx; }); +let + importWebsites = expr: import expr { tools = tools.nginx; }; + + websites = tools.nginx.mappers.mapSubdomains (importWebsites ./websites.nix); + + extraWebsites = importWebsites ./extra-sites.nix; +in { + services.nginx.virtualHosts = websites // extraWebsites; } diff --git a/hosts/VEGAS/services/websites/extra-sites.nix b/hosts/VEGAS/services/websites/extra-sites.nix new file mode 100644 index 0000000..237f55f --- /dev/null +++ b/hosts/VEGAS/services/websites/extra-sites.nix @@ -0,0 +1,10 @@ +{ tools }: +with tools.vhosts; +let + inherit (tools) domain; + + noSSL = { enableACME = false; forceSSL = false; }; +in +{ + "ky.rip" = simplePHP "/srv/storage/www/ky.rip" // noSSL; +}