From a3e9717c91aa765a21f712a85d5e227b81203627 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Wed, 4 May 2016 15:33:15 +0200 Subject: fileBin on ymir --- custom/ymir-nginx.nix | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) (limited to 'custom') diff --git a/custom/ymir-nginx.nix b/custom/ymir-nginx.nix index a36ac79e..1a02d4c7 100644 --- a/custom/ymir-nginx.nix +++ b/custom/ymir-nginx.nix @@ -90,6 +90,45 @@ in { root /srv/www/default; } + server { + listen *:80; + listen [::]:80; + listen *:443 ssl; + listen [::]:443 ssl; + server_name ~^(.*\.)?(f|files)\.(yggdrasil\.li|141\.li|praseodym\.org)$; + + include ${favicon}; + include ${acme}; + + root /srv/www/files; + } + + server { + listen *:80; + listen *:443 ssl; + listen [::]:80; + listen [::]:443 ssl; + server_name ~^(.*\.)?git\.yggdrasil\.li$; + + root ${pkgs.cgit}/cgit; + + try_files $uri @cgit; + + include ${favicon}; + include ${acme}; + + location @cgit { + include ${uwsgi_params}; + uwsgi_pass unix:/tmp/cgit.sock; + uwsgi_modifier1 9; + } + } + ''; + }; +} + + } + server { listen *:80; listen [::]:80; -- cgit v1.2.3