Add wireguard config
This commit is contained in:
		
							parent
							
								
									25e4a54ee2
								
							
						
					
					
						commit
						4a51eb5992
					
				| @ -19,10 +19,30 @@ | ||||
|   # Pick only one of the below networking options. | ||||
|   # networking.wireless.enable = true;  # Enables wireless support via wpa_supplicant. | ||||
|   networking.networkmanager.enable = true;  # Easiest to use and most distros use this by default. | ||||
| 
 | ||||
|   networking.wireguard.enable = true; | ||||
|   networking.wg-quick.interfaces = { | ||||
|     wg0 = { | ||||
|       listenPort = 59141; | ||||
|       privateKeyFile = "/etc/wireguard/wg_privkey"; | ||||
|       address = [ "10.101.111.7/32" ]; | ||||
|       dns = [ "10.101.111.1" ]; | ||||
|       mtu = 1380; | ||||
|       peers = [ | ||||
|         { | ||||
|           publicKey = "0XGa5Bh9nycdOgelLxnM3j2NZU3pQwhZSadb8adCtRg="; | ||||
|           allowedIPs = [ "10.101.111.0/24" ]; | ||||
|           endpoint = "139.144.78.247:51871"; | ||||
|           persistentKeepalive = 30; | ||||
|         } | ||||
|       ]; | ||||
|     }; | ||||
|   }; | ||||
|   networking.extraHosts = | ||||
|   '' | ||||
|     10.101.111.1 bitwarden.ekzy.is | ||||
|   ''; | ||||
| 
 | ||||
|   virtualisation.docker.enable = true; | ||||
| 
 | ||||
|   # Set your time zone. | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user