Tunnelsats / tunnelsats

Tunnel⚡Sats: Pre-configured VPN for Lightning Nodes
https://tunnelsats.github.io/tunnelsats/
MIT License
34 stars 8 forks source link

adaption of the install script to run tunnelsats on openvz/lxc virtualised linux systems (like strato.de) #78

Closed M1ch43lV closed 1 year ago

M1ch43lV commented 1 year ago

Problem: Standard WireGuard installation is not working on a v-linux server based on openVZ/lxc virtualisation platform (like strato.de), because the VM system does not allow the installation of additional Linux kernel modules, which is essential for WireGuard to work. Solution: However, the use of wireguard-go allows to run WireGuard on a user level without the need of kernel modules. It is a bit slower but fast enough for lightning node. Wireguard-go is written by the same team which writes WireGuard. Here is a link https://d.sb/2019/07/wireguard-on-openvz-lxc how to install the newest version of wireguard-go.

The command to check for modules with the command modprobe cls_group in virtualized environments should be removed, cause it produced an error, therefore aborting the loading of wireguard.

Recommendation to correct two small minor bugs of the script:

  1. check for the correct path of bash and adapt the bash path in the script automatically (/usr/bin/bash was not linked on the virtualized environment, instead it was installed to /bin/bash)
  2. if the command ip route reports an empty response for subnets, then the wireguard configuration tunneslsatsv2.conf should omit ip daddr != {$localNetworks} in the command line for PostUp = nft add chain ip %i nat ... setting up the NAT. If the variable $localNetworks is empty then wireguard reports a syntax error and stops loading.
ziggie1984 commented 1 year ago

also add an information to the install script for raspibolt users to change the listen directive in the lnd.conf to 0.0.0.0

M1ch43lV commented 1 year ago

Many big thanks to ziggie1984 to get this little tiny piece of information out of the big system!!!!