diff options
author | Gregor Kleen <gkleen@yggdrasil.li> | 2017-03-16 14:51:26 +0100 |
---|---|---|
committer | Gregor Kleen <gkleen@yggdrasil.li> | 2017-03-16 14:51:26 +0100 |
commit | 2faf437cc5c14ac5bcc9effd5c962145d05d8e3c (patch) | |
tree | 76b28ab9fcaf983032e9323bdbd417b8c44cd566 | |
parent | d10228b29b05a090556bc6b0486a0a2e674ed139 (diff) | |
download | nixos-2faf437cc5c14ac5bcc9effd5c962145d05d8e3c.tar nixos-2faf437cc5c14ac5bcc9effd5c962145d05d8e3c.tar.gz nixos-2faf437cc5c14ac5bcc9effd5c962145d05d8e3c.tar.bz2 nixos-2faf437cc5c14ac5bcc9effd5c962145d05d8e3c.tar.xz nixos-2faf437cc5c14ac5bcc9effd5c962145d05d8e3c.zip |
Reverse proxy to bragi
-rw-r--r-- | custom/ymir-nginx.nix | 23 | ||||
-rw-r--r-- | ymir.nix | 4 |
2 files changed, 25 insertions, 2 deletions
diff --git a/custom/ymir-nginx.nix b/custom/ymir-nginx.nix index 46256328..0d0ed8ce 100644 --- a/custom/ymir-nginx.nix +++ b/custom/ymir-nginx.nix | |||
@@ -136,6 +136,29 @@ in { | |||
136 | uwsgi_modifier1 9; | 136 | uwsgi_modifier1 9; |
137 | } | 137 | } |
138 | } | 138 | } |
139 | |||
140 | server { | ||
141 | server *:80; | ||
142 | server [::]:80; | ||
143 | server_name ~^(.*\.)?bragi\.(yggdrasil\.li|141\.li)$; | ||
144 | |||
145 | return 301 https://$host$request_uri; | ||
146 | } | ||
147 | |||
148 | server { | ||
149 | server *:443 ssl; | ||
150 | server [::]:443 ssl; | ||
151 | server_name ~^(.*\.)?bragi\.(yggdrasil\.li|141\.li)$; | ||
152 | |||
153 | include ${acme}; | ||
154 | |||
155 | location / { | ||
156 | auth_basic "Reverse proxy to bragi"; | ||
157 | auth_basic_user_file /srv/www/bragi/htpasswd; | ||
158 | |||
159 | proxy_pass http://bragi.asgard.yggdrasil/; | ||
160 | } | ||
161 | } | ||
139 | ''; | 162 | ''; |
140 | }; | 163 | }; |
141 | } | 164 | } |
@@ -14,9 +14,9 @@ let | |||
14 | }; | 14 | }; |
15 | }; | 15 | }; |
16 | myDomains = ["dirty-haskell.org" "www.dirty-haskell.org" "lists.dirty-haskell.org" "l.dirty-haskell.org" | 16 | myDomains = ["dirty-haskell.org" "www.dirty-haskell.org" "lists.dirty-haskell.org" "l.dirty-haskell.org" |
17 | "files.141.li" "f.141.li" "ymir.141.li" "141.li" "www.141.li" "lists.141.li" "l.141.li" | 17 | "files.141.li" "f.141.li" "ymir.141.li" "141.li" "www.141.li" "lists.141.li" "l.141.li" "bragi.141.li" |
18 | "ymir.xmpp.li" "xmpp.li" "www.xmpp.li" "lists.xmpp.li" "l.xmpp.li" | 18 | "ymir.xmpp.li" "xmpp.li" "www.xmpp.li" "lists.xmpp.li" "l.xmpp.li" |
19 | "files.yggdrasil.li" "f.yggdrasil.li" "ymir.yggdrasil.li" "git.yggdrasil.li" "www.yggdrasil.li" "yggdrasil.li" "lists.yggdrasil.li" "l.yggdrasil.li" | 19 | "files.yggdrasil.li" "f.yggdrasil.li" "ymir.yggdrasil.li" "git.yggdrasil.li" "www.yggdrasil.li" "yggdrasil.li" "lists.yggdrasil.li" "l.yggdrasil.li" "bragi.yggdrasil.li" |
20 | "files.praseodym.org" "f.praseodym.org" "ymir.praseodym.org" "praseodym.org" "www.praseodym.org" "lists.praseodym.org" "l.praseodym.org" | 20 | "files.praseodym.org" "f.praseodym.org" "ymir.praseodym.org" "praseodym.org" "www.praseodym.org" "lists.praseodym.org" "l.praseodym.org" |
21 | "ymir.kleen.li" "kleen.li" "www.kleen.li" | 21 | "ymir.kleen.li" "kleen.li" "www.kleen.li" |
22 | "ymir.nights.email" "nights.email" "www.nights.email" | 22 | "ymir.nights.email" "nights.email" "www.nights.email" |