mirror of
				https://github.com/Stunkymonkey/nixos.git
				synced 2025-10-31 01:32:11 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			33 lines
		
	
	
	
		
			732 B
		
	
	
	
		
			Nix
		
	
	
	
	
	
			
		
		
	
	
			33 lines
		
	
	
	
		
			732 B
		
	
	
	
		
			Nix
		
	
	
	
	
	
| # Get RSS feeds from websites that don't natively have one
 | |
| { config, lib, ... }:
 | |
| let
 | |
|   cfg = config.my.services.rss-bridge;
 | |
|   domain = "rss-bridge.${config.networking.domain}";
 | |
| in
 | |
| {
 | |
|   options.my.services.rss-bridge = {
 | |
|     enable = lib.mkEnableOption "RSS-Bridge service";
 | |
|   };
 | |
| 
 | |
|   config = lib.mkIf cfg.enable {
 | |
|     services.rss-bridge = {
 | |
|       enable = true;
 | |
|       whitelist = [ "*" ]; # Whitelist all
 | |
|       virtualHost = domain;
 | |
|     };
 | |
| 
 | |
|     services.nginx.virtualHosts.${domain} = {
 | |
|       forceSSL = true;
 | |
|       enableACME = true;
 | |
|     };
 | |
| 
 | |
|     webapps.apps.rss-bridge = {
 | |
|       dashboard = {
 | |
|         name = "RSS-Bridge";
 | |
|         category = "infra";
 | |
|         icon = "rss";
 | |
|         link = "https://${domain}";
 | |
|       };
 | |
|     };
 | |
|   };
 | |
| }
 | 
