mirror of
https://github.com/gravitl/netmaker.git
synced 2025-11-12 01:30:41 +08:00
test logs
This commit is contained in:
parent
c741cbfc2c
commit
1f9a94a4ed
1 changed files with 3 additions and 0 deletions
|
|
@ -3,6 +3,7 @@ package wireguard
|
||||||
import (
|
import (
|
||||||
"bufio"
|
"bufio"
|
||||||
"errors"
|
"errors"
|
||||||
|
"log"
|
||||||
"os"
|
"os"
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
@ -228,6 +229,7 @@ func getConfig(path string) string {
|
||||||
|
|
||||||
// SetMacPeerRoutes - sets routes for interface from the peer list for all AllowedIps
|
// SetMacPeerRoutes - sets routes for interface from the peer list for all AllowedIps
|
||||||
func SetMacPeerRoutes(realIface string) error {
|
func SetMacPeerRoutes(realIface string) error {
|
||||||
|
log.Println("DELETE ME: setting mac peer routes")
|
||||||
var err error
|
var err error
|
||||||
peerIPs := getPeerIPs(realIface)
|
peerIPs := getPeerIPs(realIface)
|
||||||
if len(peerIPs) == 0 {
|
if len(peerIPs) == 0 {
|
||||||
|
|
@ -235,6 +237,7 @@ func SetMacPeerRoutes(realIface string) error {
|
||||||
}
|
}
|
||||||
for _, i := range peerIPs {
|
for _, i := range peerIPs {
|
||||||
if i != "" {
|
if i != "" {
|
||||||
|
log.Println("DELETE ME: adding route " + i + " on iface " + realIface)
|
||||||
err = addRoute(i, realIface)
|
err = addRoute(i, realIface)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
ncutils.PrintLog("error adding route to "+realIface+" for "+i, 1)
|
ncutils.PrintLog("error adding route to "+realIface+" for "+i, 1)
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue