forked from fabian/nix
		
	vps: add dufs
This commit is contained in:
		
							parent
							
								
									aa14f6f7ef
								
							
						
					
					
						commit
						e62691fbda
					
				
					 4 changed files with 267 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -17,5 +17,6 @@ with lib; {
 | 
			
		|||
    ./calibre-web.nix
 | 
			
		||||
    ./immich.nix
 | 
			
		||||
    ./mealie.nix
 | 
			
		||||
    ./dufs.nix
 | 
			
		||||
  ];
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
							
								
								
									
										32
									
								
								sys/platforms/vps/srv/dufs.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										32
									
								
								sys/platforms/vps/srv/dufs.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,32 @@
 | 
			
		|||
{
 | 
			
		||||
  lib,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  config,
 | 
			
		||||
  ...
 | 
			
		||||
}:
 | 
			
		||||
with lib; {
 | 
			
		||||
  services = {
 | 
			
		||||
    nginx = {
 | 
			
		||||
      virtualHosts."public.posixlycorrect.com" = {
 | 
			
		||||
        enableACME = true;
 | 
			
		||||
        forceSSL = true;
 | 
			
		||||
        extraConfig = ''
 | 
			
		||||
          proxy_headers_hash_max_size 512;
 | 
			
		||||
          proxy_headers_hash_bucket_size 128;
 | 
			
		||||
        '';
 | 
			
		||||
        locations."/" = {
 | 
			
		||||
          proxyPass = "http://127.0.0.1:5000";
 | 
			
		||||
        };
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  local.sys.dufs = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    settings = {
 | 
			
		||||
      serve-path = "/var/public";
 | 
			
		||||
      allow-all = false;
 | 
			
		||||
      allow-archive = true;
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue