adding some automatic updates and garbage collection
This commit is contained in:
		
							parent
							
								
									69235e61fa
								
							
						
					
					
						commit
						3fe449f8d8
					
				
					 1 changed files with 16 additions and 1 deletions
				
			
		| 
						 | 
					@ -6,10 +6,25 @@ with lib;
 | 
				
			||||||
  nix = {
 | 
					  nix = {
 | 
				
			||||||
   extraOptions = "experimental-features = nix-command flakes";
 | 
					   extraOptions = "experimental-features = nix-command flakes";
 | 
				
			||||||
   package = pkgs.nixFlakes; 
 | 
					   package = pkgs.nixFlakes; 
 | 
				
			||||||
 | 
					   gc = {
 | 
				
			||||||
 | 
					     automatic = true;
 | 
				
			||||||
 | 
					     dates = "weekly";
 | 
				
			||||||
 | 
					     options = "--delete-older-than 20d";
 | 
				
			||||||
 | 
					   };
 | 
				
			||||||
 | 
					   settings = {
 | 
				
			||||||
 | 
					     auto-optimise-store = true;
 | 
				
			||||||
 | 
					   };
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					 | 
				
			||||||
  nixpkgs.config.allowUnFree = true;
 | 
					  nixpkgs.config.allowUnFree = true;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  system.autoUpgrade = {
 | 
				
			||||||
 | 
					    enable = true;
 | 
				
			||||||
 | 
					    dates = "02:00";
 | 
				
			||||||
 | 
					    allowReboot = false;
 | 
				
			||||||
 | 
					    flake = "${config.users.users.chris.home}/conf";
 | 
				
			||||||
 | 
					    flags = [ "--update-input" "nixpkgs" "--commit-lock-file" ];
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # Use the systemd-boot EFI boot loader.
 | 
					  # Use the systemd-boot EFI boot loader.
 | 
				
			||||||
  boot.loader.systemd-boot.enable = true;
 | 
					  boot.loader.systemd-boot.enable = true;
 | 
				
			||||||
  boot.loader.efi.canTouchEfiVariables = true;
 | 
					  boot.loader.efi.canTouchEfiVariables = true;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue