Add skeleton for Idacloud VPN config
This commit is contained in:
parent
fb341accbb
commit
f58e86e37b
1 changed files with 36 additions and 1 deletions
|
@ -1,6 +1,5 @@
|
|||
{ ... }:
|
||||
{
|
||||
networking.hostName = "idacloud";
|
||||
custom.nextcloud_domain = "idacloud.sinerva.eu";
|
||||
|
||||
imports = [
|
||||
|
@ -8,6 +7,42 @@
|
|||
../services/nextcloud.nix
|
||||
];
|
||||
|
||||
# Networking conf including WireGuard
|
||||
networking = {
|
||||
hostName = "idacloud";
|
||||
|
||||
firewall.allowedUDPPorts = [ 51822 ];
|
||||
|
||||
wg-quick.interfaces = {
|
||||
wg0 = {
|
||||
address = [ "10.1.0.1/24" ];
|
||||
privateKeyFile = "/root/wireguard-keys/privatekey";
|
||||
listenPort = 51822;
|
||||
|
||||
peers = [
|
||||
# Laptop
|
||||
# {
|
||||
# publicKey = "TODO";
|
||||
# presharedKeyFile = "/root/wireguard-keys/psk1";
|
||||
# allowedIPs = [ "10.1.0.2/32" ];
|
||||
# }
|
||||
# Phone
|
||||
# {
|
||||
# publicKey = "TODO";
|
||||
# presharedKeyFile = "/root/wireguard-keys/psk2";
|
||||
# allowedIPs = [ "10.1.0.3/32" ];
|
||||
# }
|
||||
# Test Phone
|
||||
{
|
||||
publicKey = "66ubJoZWX9jyPKMO2ORomokPO3CokBTGjHiOhHZLjzI=";
|
||||
presharedKeyFile = "/root/wireguard-keys/psk3";
|
||||
allowedIPs = [ "10.1.0.4/32" ];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# HARDWARE SPECIFIC
|
||||
services.qemuGuest.enable = true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue