5
0
mirror of https://github.com/cwinfo/yggdrasil-network.github.io.git synced 2024-11-10 03:20:25 +00:00

Merge pull request #6 from yggdrasil-network/unixsockets

Update documentation for UNIX admin sockets
This commit is contained in:
Arceliar 2018-07-07 14:30:15 -05:00 committed by GitHub
commit 6fb5d7f96c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 17 additions and 16 deletions

View File

@ -17,7 +17,8 @@ yggdrasilctl setTunTap name=auto mtu=65535 tap_mode=false
To perform an action on a remote Yggdrasil node, specify the `-endpoint` parameter: To perform an action on a remote Yggdrasil node, specify the `-endpoint` parameter:
``` ```
yggdrasilctl -endpoint=10.0.0.1:9001 getPeers yggdrasilctl -endpoint=tcp://10.0.0.1:9001 getPeers
yggdrasilctl -endpoint=unix:///var/run/yggdrasil.sock getDHT
``` ```
To get the JSON response body instead of a "friendly" output, specify the `-json` parameter: To get the JSON response body instead of a "friendly" output, specify the `-json` parameter:

View File

@ -16,7 +16,7 @@ A new configuration file may be generated with `yggdrasil --genconf > path/to/yg
# Listen address for admin connections Default is to listen for local # Listen address for admin connections Default is to listen for local
# connections only on TCP port 9001. # connections only on TCP port 9001.
AdminListen: localhost:9001 AdminListen: "tcp://localhost:9001"
# List of connection strings for static peers in URI format, i.e. # List of connection strings for static peers in URI format, i.e.
# tcp://a.b.c.d:e or socks://a.b.c.d:e/f.g.h.i:j # tcp://a.b.c.d:e or socks://a.b.c.d:e/f.g.h.i:j
@ -73,8 +73,9 @@ Note that any field not specified in the configuration will use its default valu
- Note that, due to Go language design choices, `[::]` listens on IPv4 and IPv6 on most platforms, while an empty IP or `0.0.0.0` listens only to IPv4. - Note that, due to Go language design choices, `[::]` listens on IPv4 and IPv6 on most platforms, while an empty IP or `0.0.0.0` listens only to IPv4.
- The default is to listen on all addresses (`[::]`) with a random port. - The default is to listen on all addresses (`[::]`) with a random port.
- `AdminListen` - `AdminListen`
- Port to listen on for the (TCP) admin socket. - Port to listen on for the admin socket, specified in URI format, i.e. `tcp://localhost:9001`.
- The default is to listen on the loopback interface (`localhost:9001`) which ensures that only local connections to the admin socket are allowed. - On supported platforms, the admin socket can listen on a UNIX domain socket instead, i.e. `unix:///var/run/yggdrasil.sock`.
- The default is to listen on the loopback interface (`tcp://localhost:9001`) which ensures that only local connections to the admin socket are allowed.
- Note that if you change the listen address to a non-loopback address, this will allow other hosts on the network to manage the Yggdrasil process. This probably isn't desirable. - Note that if you change the listen address to a non-loopback address, this will allow other hosts on the network to manage the Yggdrasil process. This probably isn't desirable.
- `Peers` - `Peers`
- A list of strings in the form `[ "peerAddress:peerPort", "peerAddress:peerPort", ... ]` of peers to connect to. - A list of strings in the form `[ "peerAddress:peerPort", "peerAddress:peerPort", ... ]` of peers to connect to.
@ -184,4 +185,3 @@ GOPATH=$PWD go run -tags debug misc/genkeys.go
This continually generates new keys and prints them out each time a new best set of keys is discovered. This continually generates new keys and prints them out each time a new best set of keys is discovered.
These keys may then be manually added to the configuration file. These keys may then be manually added to the configuration file.