feat(services): add system 76 scheduler module
This commit is contained in:
		
							parent
							
								
									701a5aea1f
								
							
						
					
					
						commit
						38232074d6
					
				
					 3 changed files with 26 additions and 0 deletions
				
			
		|  | @ -3,6 +3,7 @@ | |||
| { | ||||
|   imports = [  | ||||
|   ./mediaServer | ||||
|   ./system76Scheduler | ||||
|   ]; | ||||
| 
 | ||||
|   options.systemModules.services = { | ||||
|  |  | |||
							
								
								
									
										24
									
								
								system/modules/services/system76Scheduler/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								system/modules/services/system76Scheduler/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,24 @@ | |||
| { lib, config, ... }: | ||||
| 
 | ||||
| let | ||||
|   cfg = config.systemModules.services.system76Scheduler; | ||||
|   inherit (lib) mkEnableOption mkIf; | ||||
| in | ||||
| 
 | ||||
| { | ||||
|   options.systemModules.services.system76Scheduler = { | ||||
|     enable = mkEnableOption "Enable system 76 scheduler module"; | ||||
|   }; | ||||
| 
 | ||||
|   config = mkIf cfg.enable { | ||||
| 
 | ||||
|     services.system76-scheduler = { | ||||
|       enable = true; | ||||
|     }; | ||||
|     # fix suspend issues | ||||
|     powerManagement = { | ||||
|       powerDownCommands = "systemctl stop system76-scheduler"; | ||||
|       resumeCommands = "systemctl start system76-scheduler"; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue