]> git.immae.eu Git - perso/Immae/Config/Nix.git/blobdiff - systems/eldiron/websites/immae/production.nix
Add patch pages
[perso/Immae/Config/Nix.git] / systems / eldiron / websites / immae / production.nix
index e4060ba4852220ee2cee06359a58800ef0c10fc8..2ed4a7d748a96b6f3eeda91a595a890df3696205 100644 (file)
@@ -4,6 +4,7 @@ let
   varDir = "/var/lib/buildbot/outputs/immae/blog";
   historyDir = "/var/lib/buildbot/outputs/immae/history";
   docsDir = "/var/lib/buildbot/outputs/immae/docs/";
+  patchesDir = "/var/lib/buildbot/outputs/immae/patches/";
 in {
   options.myServices.websites.immae.production.enable = lib.mkEnableOption "enable Immae's website";
 
@@ -19,6 +20,7 @@ in {
     security.acme.certs.immae.extraDomainNames = [ "immae.eu" ];
     services.websites.env.production.bindMounts."${varDir}" = {};
     services.websites.env.production.bindMounts."${docsDir}" = {};
+    services.websites.env.production.bindMounts."${patchesDir}" = {};
     services.websites.env.production.bindMounts."${historyDir}" = {};
     services.websites.env.production.vhostConfs.immae_production = {
       certName     = "immae";
@@ -56,6 +58,14 @@ in {
           Header always set Access-Control-Allow-Origin "*"
         </Directory>
 
+        Alias /patches ${patchesDir}
+        <Directory ${patchesDir}>
+          DirectoryIndex index.htm index.html
+          Options Indexes FollowSymLinks MultiViews Includes
+          AllowOverride All
+          Require all granted
+        </Directory>
+
         Alias /docs ${docsDir}
         <Directory ${docsDir}>
           DirectoryIndex index.htm index.html