sync conf

This commit is contained in:
0xdcarns
2022-01-31 11:25:05 -05:00
parent feb34722c2
commit 3aaf83d04d
2 changed files with 9 additions and 3 deletions

View File

@@ -285,10 +285,10 @@ func UpdatePeers(client mqtt.Client, msg mqtt.Message) {
ncutils.Log("error updating wireguard peers" + err.Error())
return
}
ncutils.Log("applyWGQuickConf to " + file)
err = wireguard.ApplyWGQuickConf(file)
ncutils.Log("syncing conf to " + file)
err = wireguard.SyncWGQuickConf(cfg.Node.Interface, file)
if err != nil {
ncutils.Log("error restarting wg after peer update " + err.Error())
ncutils.Log("error syncing wg after peer update " + err.Error())
return
}
}