static configs

This commit is contained in:
afeiszli
2021-08-09 14:13:19 -04:00
parent f8df4b571b
commit aae89cbaca
5 changed files with 18 additions and 30 deletions

View File

@@ -82,7 +82,8 @@ func InitWireguard(node *models.Node, privkey string, peers []wgtypes.PeerConfig
conf := wgtypes.Config{}
if nodecfg.UDPHolePunch == "yes" &&
nodecfg.IsServer == "no" &&
nodecfg.IsIngressGateway == "no" {
nodecfg.IsIngressGateway == "no" &&
nodecfg.IsStatic != "yes" {
conf = wgtypes.Config{
PrivateKey: &key,
ReplacePeers: true,