fixed iptable directory changes

This commit is contained in:
2023-04-14 10:54:24 +01:00
parent 97d10918b1
commit 3bcba8a3e2
3 changed files with 130 additions and 128 deletions

View File

@@ -18,6 +18,9 @@ var CliAction = func(ctx *cli.Context) error {
fmt.Print(err)
}
//server.Rpc()
for {
}
}
//Listing servers and also updates IP tables (Default 3 hops)
@@ -135,7 +138,7 @@ var CliAction = func(ctx *cli.Context) error {
//Sets default paths to the config file
if SetDefaultConfig {
_, err := generate.SetDefaults("P2PRC", false, nil, true)
_, err := generate.SetDefaults("P2PRC", false, nil, false)
if err != nil {
fmt.Print(err)
}

View File

@@ -54,6 +54,7 @@ func CreateIPTableFolderStructure() (err error) {
if err = os.Mkdir(path+"p2p", os.ModePerm); err != nil {
return err
}
}
if _, err = os.Stat(path + "p2p/iptable"); os.IsNotExist(err) {
if err = os.Mkdir(path+"p2p/iptable", os.ModePerm); err != nil {
return err
@@ -66,8 +67,6 @@ func CreateIPTableFolderStructure() (err error) {
}
}
}
return
}

View File

@@ -2,7 +2,7 @@
"ip_address": [
{
"Name": "Node1",
"IPV4": "64.227.168.102",
"IPV4": "164.90.177.167",
"IPV6": "",
"Latency": 0,
"ServerPort": "8088",