Compare commits
	
		
			3 Commits
		
	
	
		
			22271d33d1
			...
			0b5beaf63d
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
|   | 0b5beaf63d | ||
|   | 03604f9352 | ||
|   | 5047f1ab24 | 
							
								
								
									
										32
									
								
								flake.lock
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										32
									
								
								flake.lock
									
									
									
										generated
									
									
									
								
							| @ -7,11 +7,11 @@ | |||||||
|         ] |         ] | ||||||
|       }, |       }, | ||||||
|       "locked": { |       "locked": { | ||||||
|         "lastModified": 1748225455, |         "lastModified": 1750040002, | ||||||
|         "narHash": "sha256-AzlJCKaM4wbEyEpV3I/PUq5mHnib2ryEy32c+qfj6xk=", |         "narHash": "sha256-KrC9iOVYIn6ukpVlHbqSA4hYCZ6oDyJKrcLqv4c5v84=", | ||||||
|         "owner": "nix-community", |         "owner": "nix-community", | ||||||
|         "repo": "disko", |         "repo": "disko", | ||||||
|         "rev": "a894f2811e1ee8d10c50560551e50d6ab3c392ba", |         "rev": "7f1857b31522062a6a00f88cbccf86b43acceed1", | ||||||
|         "type": "github" |         "type": "github" | ||||||
|       }, |       }, | ||||||
|       "original": { |       "original": { | ||||||
| @ -61,11 +61,11 @@ | |||||||
|         ] |         ] | ||||||
|       }, |       }, | ||||||
|       "locked": { |       "locked": { | ||||||
|         "lastModified": 1748134483, |         "lastModified": 1750107071, | ||||||
|         "narHash": "sha256-5PBK1nV8X39K3qUj8B477Aa2RdbLq3m7wRxUKRtggX4=", |         "narHash": "sha256-yfuHCO4m+gu3OBNGnP0/TL5W8nLXrC/EV1fs/+YcoL8=", | ||||||
|         "owner": "nix-community", |         "owner": "nix-community", | ||||||
|         "repo": "home-manager", |         "repo": "home-manager", | ||||||
|         "rev": "c1e671036224089937e111e32ea899f59181c383", |         "rev": "0edffd088e42fdc48598b37d88eb5345e2ca3937", | ||||||
|         "type": "github" |         "type": "github" | ||||||
|       }, |       }, | ||||||
|       "original": { |       "original": { | ||||||
| @ -133,11 +133,11 @@ | |||||||
|     }, |     }, | ||||||
|     "nixpkgs": { |     "nixpkgs": { | ||||||
|       "locked": { |       "locked": { | ||||||
|         "lastModified": 1747958103, |         "lastModified": 1749903597, | ||||||
|         "narHash": "sha256-qmmFCrfBwSHoWw7cVK4Aj+fns+c54EBP8cGqp/yK410=", |         "narHash": "sha256-jp0D4vzBcRKwNZwfY4BcWHemLGUs4JrS3X9w5k/JYDA=", | ||||||
|         "owner": "nixos", |         "owner": "nixos", | ||||||
|         "repo": "nixpkgs", |         "repo": "nixpkgs", | ||||||
|         "rev": "fe51d34885f7b5e3e7b59572796e1bcb427eccb1", |         "rev": "41da1e3ea8e23e094e5e3eeb1e6b830468a7399e", | ||||||
|         "type": "github" |         "type": "github" | ||||||
|       }, |       }, | ||||||
|       "original": { |       "original": { | ||||||
| @ -161,11 +161,11 @@ | |||||||
|     }, |     }, | ||||||
|     "secrets": { |     "secrets": { | ||||||
|       "locked": { |       "locked": { | ||||||
|         "lastModified": 1749476519, |         "lastModified": 1750361251, | ||||||
|         "narHash": "sha256-yzSsn2e+n4TQisd1PB7vZLcz9rhd8n5V4uoniWt+CP8=", |         "narHash": "sha256-yfK2ArCYImg5vIfWP8f2O9+TF18K0dGOVqjheI23zuo=", | ||||||
|         "ref": "refs/heads/main", |         "ref": "refs/heads/main", | ||||||
|         "rev": "890c1295ca6fea2a3aad5b7075dd5902f92beef0", |         "rev": "498db9fadb1810dd2c3e5d130b655ff7632f9640", | ||||||
|         "revCount": 13, |         "revCount": 14, | ||||||
|         "type": "git", |         "type": "git", | ||||||
|         "url": "ssh://gitea@git.bulthuis.dev/Jan/nixos-secrets" |         "url": "ssh://gitea@git.bulthuis.dev/Jan/nixos-secrets" | ||||||
|       }, |       }, | ||||||
| @ -181,11 +181,11 @@ | |||||||
|         ] |         ] | ||||||
|       }, |       }, | ||||||
|       "locked": { |       "locked": { | ||||||
|         "lastModified": 1747603214, |         "lastModified": 1749592509, | ||||||
|         "narHash": "sha256-lAblXm0VwifYCJ/ILPXJwlz0qNY07DDYdLD+9H+Wc8o=", |         "narHash": "sha256-VunQzfZFA+Y6x3wYi2UE4DEQ8qKoAZZCnZPUlSoqC+A=", | ||||||
|         "owner": "Mic92", |         "owner": "Mic92", | ||||||
|         "repo": "sops-nix", |         "repo": "sops-nix", | ||||||
|         "rev": "8d215e1c981be3aa37e47aeabd4e61bb069548fd", |         "rev": "50754dfaa0e24e313c626900d44ef431f3210138", | ||||||
|         "type": "github" |         "type": "github" | ||||||
|       }, |       }, | ||||||
|       "original": { |       "original": { | ||||||
|  | |||||||
| @ -50,22 +50,39 @@ | |||||||
|     enable = true; |     enable = true; | ||||||
|     systemCronJobs = |     systemCronJobs = | ||||||
|       let |       let | ||||||
|         script = pkgs.writeShellScript "backup-script" '' |         script = pkgs.writeShellScript "backup-script" ( | ||||||
|  |           lib.concatStrings ( | ||||||
|  |             [ | ||||||
|  |               '' | ||||||
|                 . ${config.sops.secrets."backup-script-env".path} |                 . ${config.sops.secrets."backup-script-env".path} | ||||||
|                 export PBS_REPOSITORY=$PBS_REPOSITORY |                 export PBS_REPOSITORY=$PBS_REPOSITORY | ||||||
|                 export PBS_NAMESPACE=$PBS_NAMESPACE |                 export PBS_NAMESPACE=$PBS_NAMESPACE | ||||||
|                 export PBS_PASSWORD=$PBS_PASSWORD |                 export PBS_PASSWORD=$PBS_PASSWORD | ||||||
|                 export PBS_FINGERPRINT=$PBS_FINGERPRINT |                 export PBS_FINGERPRINT=$PBS_FINGERPRINT | ||||||
|           ${pkgs.proxmox-backup-client}/bin/proxmox-backup-client backup nfs.pxar:/mnt/nas --ns $PBS_NAMESPACE --backup-id nas-backup --change-detection-mode=metadata --exclude "#recycle" |               '' | ||||||
|         ''; |             ] | ||||||
|  |             ++ lib.map (share: '' | ||||||
|  |               ${pkgs.proxmox-backup-client}/bin/proxmox-backup-client backup nfs.pxar:/mnt/${share} --ns $PBS_NAMESPACE --backup-id share-${share} --change-detection-mode=metadata --exclude "#recycle" | ||||||
|  |             '') inputs.secrets.lab.nas.backupShares | ||||||
|  |           ) | ||||||
|  |         ); | ||||||
|       in |       in | ||||||
|       [ |       [ | ||||||
|         "0 0 * * * ${script} " |         "0 0 * * * ${script} " | ||||||
|       ]; |       ]; | ||||||
|   }; |   }; | ||||||
|   fileSystems."/mnt/nas" = { | 
 | ||||||
|     device = "//${inputs.secrets.lab.nas.host}/Backup"; |   # Mount filesystems | ||||||
|  |   fileSystems = lib.listToAttrs ( | ||||||
|  |     lib.map (share: { | ||||||
|  |       name = "/mnt/${share}"; | ||||||
|  |       value = { | ||||||
|  |         device = "//${inputs.secrets.lab.nas.host}/${share}"; | ||||||
|         fsType = "cifs"; |         fsType = "cifs"; | ||||||
|     options = [ "sec=krb5,credentials=${config.sops.secrets."smb-credentials".path}" ]; |         options = [ | ||||||
|  |           "sec=krb5,credentials=${config.sops.secrets."smb-credentials".path}" | ||||||
|  |         ]; | ||||||
|       }; |       }; | ||||||
|  |     }) inputs.secrets.lab.nas.backupShares | ||||||
|  |   ); | ||||||
| } | } | ||||||
|  | |||||||
| @ -17,10 +17,9 @@ in | |||||||
| 
 | 
 | ||||||
|   config = mkIf cfg.enable { |   config = mkIf cfg.enable { | ||||||
|     # Enable GDM and Gnome |     # Enable GDM and Gnome | ||||||
|     services.xserver.enable = true; |     services.displayManager.gdm.enable = true; | ||||||
|     services.xserver.displayManager.gdm.enable = true; |     services.desktopManager.gnome.enable = true; | ||||||
|     services.xserver.desktopManager.gnome.enable = true; |     services.gnome.core-apps.enable = false; | ||||||
|     services.gnome.core-utilities.enable = false; |  | ||||||
|     services.gnome.games.enable = false; |     services.gnome.games.enable = false; | ||||||
|     services.gnome.core-developer-tools.enable = false; |     services.gnome.core-developer-tools.enable = false; | ||||||
|     environment.gnome.excludePackages = with pkgs; [ |     environment.gnome.excludePackages = with pkgs; [ | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user