home-manager: update
[julm/julm-nix.git] / hosts / aubergine / nginx / aubergine.nix
index 386cf84ba8801b3d3c420587586f31f43785072f..e3f9cf778ab279bf884937c08e3a8d2c9db05cae 100644 (file)
@@ -1,4 +1,9 @@
-{ lib, config, hostName, ... }:
+{
+  lib,
+  config,
+  hostName,
+  ...
+}:
 with (import ../networking/names-and-numbers.nix);
 let
   inherit (config.networking) domain;
@@ -26,13 +31,24 @@ in
         #autoindex on;
         return 444;
       '';
-      locations."/perso" = {
+      locations."/perso/photo" = {
+        #basicAuthFile = gnupg.secrets."nginx/perso/htpasswd".path;
+        extraConfig = ''
+          autoindex on;
+          #fancyindex on;
+          #fancyindex_exact_size off;
+          #fancyindex_name_length 255;
+          open_file_cache off;
+          #open_file_cache_valid 1s;
+        '';
+      };
+      locations."/perso/camera" = {
         #basicAuthFile = gnupg.secrets."nginx/perso/htpasswd".path;
         extraConfig = ''
           autoindex on;
-          fancyindex on;
-          fancyindex_exact_size off;
-          fancyindex_name_length 255;
+          #fancyindex on;
+          #fancyindex_exact_size off;
+          #fancyindex_name_length 255;
           open_file_cache off;
           #open_file_cache_valid 1s;
         '';
@@ -45,7 +61,8 @@ in
         "nginx/${domain}/${hostName}"
       ];
       BindReadOnlyPaths = [
-        "-/mnt/off2/julm/backup/das1/julm/perso:${root}/perso"
+        "-/mnt/off2/julm/backup/das1/julm/perso/photo:${root}/perso/photo"
+        "-/mnt/off2/julm/perso/camera:${root}/perso/camera"
       ];
     };
   };