diff --git a/JoinTestNetwork.md b/JoinTestNetwork.md deleted file mode 100644 index 502dc16..0000000 --- a/JoinTestNetwork.md +++ /dev/null @@ -1,107 +0,0 @@ -# Join nConnect Test Nework - -* The nConnect manager address: -`manager.7cafe0ae02789f8eb6b293e46b0ac5cf8f92f73042199c8161e5b5f90b13dcb5` -* The nConnect manager web url: -`http://147.182.218.42:8000/network` -* The test nework IP scope: -`10.0.86.2 ~ 10.0.86.254` - -Please follow these steps to join or manage the test network. - -> On Unix-like systems you may need to preface commands with sudo, while on Windows you will need to use an administrator-mode command prompt. - -## 1. Clone nConnect Repository: -``` -git clone -b network https://github.com/billfort/nconnect -``` - -## 2. Compile nConnect - -* Linux or MacOs: -``` -make -``` - -* Windows: -``` -go build -o nConnect.exe bin/main.go -``` - -## 3. Start nConnect Manager [optional] -The manager node usually is running. If nConnect network manager is not available, you can log into `147.182.218.42` to start it - -``` -./nConnect -m -f config.manager.json -``` - -## 4. Conifg Network Member Node - -``` -cp config.network.json config.member.json -``` - -``` -vi config.member.json -``` - -Edit `identifier`, `managerAddress`, `nodeName` and `seed`. - -``` -{ - "identifier": "alice", // your nkn client identifier, such alice, bruce, bill, max, ... - "managerAddress": "manager.7cafe0ae02789f8eb6b293e46b0ac5cf8f92f73042199c8161e5b5f90b13dcb5", // This is testing manager address. - "nodeName": "alice", // It can be as same as identifier, or different. it is used only in network node naming. - "seed": "", // If you want other nodes can access your node, you need start nConnect server, make sure your wallet have NKN balance. -} -``` - -## 5. Start nConnect Network Member Node - -* Linux or Mac OS in root - -``` -./nConnect -n -s -c -f config.member.json --tuna --vpn --udp -``` - -* Windows Powershell Administrator - -``` -./nConnect.exe -n -s -c -f config.member.json --tuna --vpn --udp -``` - -## 6. Wait for nConnect Manager to Authorize Your Joining. - -Open the network manager web page `http://147.182.218.42:8000/network`, and refresh `Wait for Authorization` section, should see the new member node. Click "Accept" to authorize the new member. You can check `Accept All Member` to set your node is accessible for all members. - -After the manager authorize your node joining, you should see a console message printed, such as: - -``` -Congratulations!!! nConnect network member authorized, IP: 10.0.86.xxx, mask: 255.255.255.0 -``` - -The `ip 10.0.86.xxx` is your IP in this private network. - -## 7. Test newtork access: - -To test your network, you can run a TCP/UDP server on a member node, and run a TCP/UDP client on another member node to do some echo tests. - -* Start a TCP and UDP server, so another node can access your node - -``` -go run tests/tools/main.go -server -``` - -* Start a TCP client to access another node if you know his IP, such as making an echo test to `10.0.86.3` node: - -``` -go run tests/tools/main.go -serverAddr 10.0.86.3 -``` - -* Start a UDP client to access another node if you know his IP, such as making an echo test to `10.0.86.3` node: - -``` -go run tests/tools/main.go -serverAddr 10.0.86.3 -udp -``` - -You should see both the server and client's echo test messages. diff --git a/go.mod b/go.mod index 14a73db..c1c92b8 100644 --- a/go.mod +++ b/go.mod @@ -11,8 +11,8 @@ require ( github.com/jessevdk/go-flags v1.5.0 github.com/nknorg/ncp-go v1.0.6-0.20230228002512-f4cd1740bebd github.com/nknorg/nkn-sdk-go v1.4.6-0.20230404044330-ad192f36d07e - github.com/nknorg/nkn-tuna-session v0.2.6-0.20230821020533-3e6e2effd7a3 - github.com/nknorg/nkn-tunnel v0.3.5-0.20230821022131-3d996fff45f4 + github.com/nknorg/nkn-tuna-session v0.2.6 + github.com/nknorg/nkn-tunnel v0.3.5 github.com/nknorg/nkn/v2 v2.2.0 github.com/nknorg/nkngomobile v0.0.0-20220615081414-671ad1afdfa9 github.com/nknorg/tuna v0.0.0-20230818024750-e800a743f680 diff --git a/go.sum b/go.sum index b1f0503..72cb274 100644 --- a/go.sum +++ b/go.sum @@ -127,10 +127,10 @@ github.com/nknorg/ncp-go v1.0.6-0.20230228002512-f4cd1740bebd h1:ZAXKeWKjkbS9QQh github.com/nknorg/ncp-go v1.0.6-0.20230228002512-f4cd1740bebd/go.mod h1:T7ThlxmBjVIv3Ll3gJOHbQTuAFN3ZCYWvbux6JOX5wQ= github.com/nknorg/nkn-sdk-go v1.4.6-0.20230404044330-ad192f36d07e h1:lWKUEfqOJ9NImCX60Bden+Y6VgRDhlx4gc6B09S32RQ= github.com/nknorg/nkn-sdk-go v1.4.6-0.20230404044330-ad192f36d07e/go.mod h1:mnI1+17p2cI+5wv+3CWRyCjSALqUg5k1jTaWC2h0f/M= -github.com/nknorg/nkn-tuna-session v0.2.6-0.20230821020533-3e6e2effd7a3 h1:boQVIScL1yhrZTv2EEdd230LCSgl1wTYCMNk1UzXD2A= -github.com/nknorg/nkn-tuna-session v0.2.6-0.20230821020533-3e6e2effd7a3/go.mod h1:sg7R0EDolPYfmP8gc5prat/hBw6dTaFOA8kqS6VSswo= -github.com/nknorg/nkn-tunnel v0.3.5-0.20230821022131-3d996fff45f4 h1:qN28HhlVKos6t2XuXxrWUKBz5vI33mAsCvEwoFTy3Y8= -github.com/nknorg/nkn-tunnel v0.3.5-0.20230821022131-3d996fff45f4/go.mod h1:VarxPJnDpAqSQ1qETpy5zLconqncwccLC3LU68XAipA= +github.com/nknorg/nkn-tuna-session v0.2.6 h1:NsZIUHQdUU6fFIWBjl2i78mdZsaOjeeJ/G/EmxSEkSw= +github.com/nknorg/nkn-tuna-session v0.2.6/go.mod h1:sg7R0EDolPYfmP8gc5prat/hBw6dTaFOA8kqS6VSswo= +github.com/nknorg/nkn-tunnel v0.3.5 h1:jHNCtQDQyLhK969CQQxB7cNxYmSyXn0/UXq4LFx9OWs= +github.com/nknorg/nkn-tunnel v0.3.5/go.mod h1:VarxPJnDpAqSQ1qETpy5zLconqncwccLC3LU68XAipA= github.com/nknorg/nkn/v2 v2.2.0 h1:sXOawvVF/T3bBTuWbzBCyrGuxldA3be+f+BDjoWcOEA= github.com/nknorg/nkn/v2 v2.2.0/go.mod h1:yv3jkg0aOtN9BDHS4yerNSZJtJNBfGvlaD5K6wL6U3E= github.com/nknorg/nkngomobile v0.0.0-20220615081414-671ad1afdfa9 h1:Gr37j7Ttvcn8g7TdC5fs6Y6IJKdmfqCvj03UbsrS77o=