Add wikijs for Aux
As part of the infra and docs teams for Auxolotl, we've decided to host
their wiki for them.
This was difficult for a few reasons
- They do not use Cloudflare, so our standard https certificate
provisioning will not work
- They do not want our automatic www subdomains
- We already run wiki.js for TransPlace, and are not able to take that
down. Nix doesn't allow us to add multiple wiki.js instances alongside
each other
- This is not permanent, so we want to make it really easy to move to
another server at a moment's notice, for example we don't want to tie
it in to our postgres server
As a mitigation for these
- We override our normal ACME configuration. This forces cloudflare by
default. We have added an "ugly hack" to avoid it forcing cloudflare
for aux
- We update helpers to add a "specific" domain, i.e. do not add www
aliases
- We use a nix container to host the wiki.js and another postgres server
Change-Id: Iecead03467f2b4a958d83cc6f92a8a0304323e35
Reviewed-on: https://git.clicks.codes/c/Infra/NixFiles/+/682
Tested-by: Skyler Grey <minion@clicks.codes>
Reviewed-by: Samuel Shuert <coded@clicks.codes>
diff --git a/modules/common/nginx-routes.nix b/modules/common/nginx-routes.nix
index cb7004d..a4af2a8 100644
--- a/modules/common/nginx-routes.nix
+++ b/modules/common/nginx-routes.nix
@@ -30,6 +30,8 @@
(ReverseProxy "generic:1035")
]))
+ (SpecificHost "wiki.auxolotl.org" (ReverseProxy "10.0.101.2:1024")) # see aux.nix
+ (SpecificHost "docs.auxolotl.org" (Path ''~ ^/?([^\r\n]*)$'' (Redirect "https://wiki.auxolotl.org/$1")))
(Host "signup.hopescaramels.com" (ReverseProxy "caramels:1024"))
(Host "freeflowtaekwondo.com" (ReverseProxy "generic:1026"))
(Host "homebridge.coded.codes" (ReverseProxy "CodedPi:8581"))