diff --git a/cmd/skywire-cli/README.md b/cmd/skywire-cli/README.md
index 965ea07da1..d7be27e938 100644
--- a/cmd/skywire-cli/README.md
+++ b/cmd/skywire-cli/README.md
@@ -134,10 +134,11 @@ Flags:
-g, --disableapps string comma separated list of apps to disable
-i, --ishv local hypervisor configuration
-j, --hvpks string list of public keys to use as hypervisor
- -k, --os string (linux / macos / windows) paths (default "linux")
+ -k, --os string (linux / mac / win) paths (default "linux")
-n, --stdout write config to stdout
- -o, --out string output config default:skywire-config.json
- -p, --package use paths for package /opt/skywire
+ -o, --out string output config: skywire-config.json
+ -p, --pkg use path for package: /opt/skywire
+ -u, --user use paths for user space: /home/user
-q, --publicrpc allow rpc requests from LAN
-r, --regen re-generate existing config & retain keys
-s, --sk cipher.SecKey a random key is generated if unspecified
@@ -147,14 +148,14 @@ Flags:
-w, --hide dont print the config to the terminal
-x, --retainhv retain existing hypervisors with regen
--version string custom version testing override
- --print string parse test ; read config from file & print
+ --binpath string set bin_path
-h, --help help for gen
-
```
##### Example defaults
The default visor config generation assumes the command is run from the root of the cloned repository.
+The example further assumes the compiled binary is available in the executable PATH and that GOPATH is set
@@ -163,14 +164,16 @@ cd $GOPATH/src/github.com/skycoin/skywire && skywire-cli config gen
```
-$ cd $GOPATH/src/github.com/skycoin/skywire && skywire-cli config gen
-[2022-04-02T18:19:57-05:00] INFO []: Fetched service endpoints from 'http://conf.skywire.skycoin.com'
-[2022-04-02T18:19:57-05:00] INFO [visor:config]: Flushing config to file. config_version="0.6.0" filepath="/home/user/go/src/github.com/skycoin/skywire/skywire-config.json"
-[2022-04-02T18:19:57-05:00] INFO [skywire-cli]: Updated file '/home/user/go/src/github.com/skycoin/skywire/skywire-config.json' to:
+$ cd $GOPATH/src/github.com/skycoin/skywire
+$ skywire-cli config gen
+[user@linux skywire]$ go run cmd/skywire-cli/skywire-cli.go config gen
+[2022-05-26T17:17:01-05:00] INFO []: Fetched service endpoints from 'http://conf.skywire.skycoin.com'
+[2022-05-26T17:17:01-05:00] INFO [visor:config]: Flushing config to file. config_version="v1.0.0" filepath="/home/user/go/src/github.com/skycoin/skywire/skywire-config.json"
+[2022-05-26T17:17:01-05:00] INFO [skywire-cli]: Updated file 'skywire-config.json' to:
{
- "version": "0.6.0",
- "sk": "1d9bdf39d1f0bafb0eef0c3c8189cfceb49f3819e4ec45b9018d6993856341f7",
- "pk": "032268ff324790954145d3bdaa9eb936fa400bd7d12de78251d85d042f09e6aca7",
+ "version": "v1.0.0",
+ "sk": "7df293067dc1942e5e1484a945120da4729819166ad8e02341b13dfd4d5469bd",
+ "pk": "03caa7c5ea048c8200538ff81f53ffad08cc289f280f2cfce9c261ea8b03405097",
"dmsg": {
"discovery": "http://dmsgd.skywire.skycoin.com",
"sessions_count": 1,
@@ -274,13 +277,13 @@ skywire-cli config gen -i
```
$ skywire-cli config gen -i
-[2022-04-02T18:21:40-05:00] INFO []: Fetched service endpoints from 'http://conf.skywire.skycoin.com'
-[2022-04-02T18:21:40-05:00] INFO [visor:config]: Flushing config to file. config_version="0.6.0" filepath="/home/user/go/src/github.com/skycoin/skywire/skywire-config.json"
-[2022-04-02T18:21:40-05:00] INFO [skywire-cli]: Updated file '/home/user/go/src/github.com/skycoin/skywire/skywire-config.json' to:
+[2022-05-26T17:21:48-05:00] INFO []: Fetched service endpoints from 'http://conf.skywire.skycoin.com'
+[2022-05-26T17:21:48-05:00] INFO [visor:config]: Flushing config to file. config_version="v1.0.0" filepath="/home/user/go/src/github.com/skycoin/skywire/skywire-config.json"
+[2022-05-26T17:21:48-05:00] INFO [skywire-cli]: Updated file 'skywire-config.json' to:
{
- "version": "0.6.0",
- "sk": "83df03537d74760487bfd12e11e6af1dbd2617b95b0b0f6637ee46a3f30822d7",
- "pk": "03761d143ec62d12e46802c111cbb59af276c05380453415720048fffaf1841971",
+ "version": "v1.0.0",
+ "sk": "053a98a9e69a80d7359297991f46a6d1b57c20f4d86a2f6dac60fbd9ef342a24",
+ "pk": "02aebbac3f4c0cb2a5606ab6d6d63ea88dd8e53255d3413c733c5588ff5acf2305",
"dmsg": {
"discovery": "http://dmsgd.skywire.skycoin.com",
"sessions_count": 1,
@@ -370,8 +373,8 @@ $ skywire-cli config gen -i
"db_path": "/home/user/go/src/github.com/skycoin/skywire/users.db",
"enable_auth": false,
"cookies": {
- "hash_key": "07ce3017177de46cc7d80b91a328864e3bf67ffd9283da3f59960abd5aecce29edab80bc7b51576c81f03b23854997937744716132f575c4f18598e6f5e9b727",
- "block_key": "614919a5c15de37f24fd6d01ad164b0fb724a052dd63cf469e116144ec2c1f0c",
+ "hash_key": "80b9c82cff3280592ca91e9f3d276f4b7c900551a24ef4f311567d21ad19d63dbdda75d3cbcce24863124151ba6d07846def16cb300cd2bd87117e802c743ac4",
+ "block_key": "d113be28b2a4b256dafde1598651b0f402b27912fb38b8449ba0b9a6c947775c",
"expires_duration": 43200000000000,
"path": "/",
"domain": ""
@@ -387,7 +390,7 @@ $ skywire-cli config gen -i
-Note that it is possible to start the visor with the hypervisor interface explicitly now, regardless of how the config was generated; using the -f flag
+Note that it is possible to start the visor with the hypervisor interface explicitly; regardless of how the config was generated; using the -i flag
```
skywire-visor -i
@@ -401,7 +404,7 @@ The dmsghttp-config.json file must be present to generate a config with dmsghttp
The `-b` or `--bestproto` flag will automatically determine if dmsghttp should be used based on region
-The `-d` or `--dmsghttp` flag creates the config with dmsghttp
+The `-d` or `--dmsghttp` flag explicitly creates the config with dmsghttp
It is recommended to use the `-b` flag for config file generation.
@@ -414,14 +417,14 @@ skywire-cli config gen -d
```
-[2022-04-02T18:32:32-05:00] INFO [skywire-cli]: Found Dmsghttp config: dmsghttp-config.json
-[2022-04-02T18:32:32-05:00] INFO []: Fetched service endpoints from 'http://conf.skywire.skycoin.com'
-[2022-04-02T18:32:32-05:00] INFO [visor:config]: Flushing config to file. config_version="0.6.0" filepath="/home/user/go/src/github.com/skycoin/skywire/skywire-config.json"
-[2022-04-02T18:32:32-05:00] INFO [skywire-cli]: Updated file '/home/user/go/src/github.com/skycoin/skywire/skywire-config.json' to:
+[2022-05-26T17:30:06-05:00] INFO [skywire-cli]: Found Dmsghttp config: dmsghttp-config.json
+[2022-05-26T17:30:07-05:00] INFO []: Fetched service endpoints from 'http://conf.skywire.skycoin.com'
+[2022-05-26T17:30:07-05:00] INFO [visor:config]: Flushing config to file. config_version="v1.0.0" filepath="/home/user/go/src/github.com/skycoin/skywire/skywire-config.json"
+[2022-05-26T17:30:07-05:00] INFO [skywire-cli]: Updated file 'skywire-config.json' to:
{
- "version": "0.6.0",
- "sk": "85577beed6b46b67704c52d3acd7ceb14a8d758356dff23028def4e38b72822f",
- "pk": "02f0cd75987be4c014d59c6aeb43095d8f68bde525e03eff63fa13e59721e397eb",
+ "version": "v1.0.0",
+ "sk": "4aaa3cc266cb8c4ec9689a0d88c49802646517ae2d2240315c480d461c6af70e",
+ "pk": "0291b61ab823eebe79575d6d0f8e122e84cd17dae1cab5c7dfb9043f1ee4f0a206",
"dmsg": {
"discovery": "dmsg://022e607e0914d6e7ccda7587f95790c09e126bbd506cc476a1eda852325aadd1aa:80",
"sessions_count": 1,
@@ -575,7 +578,9 @@ skywire-cli config gen -d
##### Example package based installation defaults
-This assumes the skywire installation is at `/opt/skywire` with binaries and apps in their own subdirectories.
+This assumes the skywire linux installation is at `/opt/skywire` with binaries and apps in their own subdirectories.
+The `-p` flag default paths are provided by the skywire linux / mac packages or windows .msi installer and generate the skywire config within the install dir.
+
@@ -586,13 +591,13 @@ sudo skywire-cli config gen -bipr
```
$ sudo skywire-cli config gen -bipr
[sudo] password for user:
-[2022-04-02T18:39:43-05:00] INFO []: Fetched service endpoints from 'http://conf.skywire.skycoin.com'
-[2022-04-02T18:39:43-05:00] INFO [visor:config]: Flushing config to file. config_version="0.6.0" filepath="/opt/skywire/skywire.json"
-[2022-04-02T18:39:43-05:00] INFO [skywire-cli]: Updated file '/opt/skywire/skywire.json' to:
+[2022-05-26T17:43:42-05:00] INFO []: Fetched service endpoints from 'http://conf.skywire.skycoin.com'
+[2022-05-26T17:43:42-05:00] INFO [visor:config]: Flushing config to file. config_version="1.0.0" filepath="/opt/skywire/skywire.json"
+[2022-05-26T17:43:42-05:00] INFO [skywire-cli]: Updated file '/opt/skywire/skywire.json' to:
{
- "version": "0.6.0",
- "sk": "077017551b6a993b06d684426436794d661347191570c7ea4ed1fe25bfac5269",
- "pk": "02afbeaa4f02251091eccd7d66e300ca8e3a406020d969ea20089a49d4e6fe2fa3",
+ "version": "1.0.0",
+ "sk": "4aaa3cc266cb8c4ec9689a0d88c49802646517ae2d2240315c480d461c6af70e",
+ "pk": "0291b61ab823eebe79575d6d0f8e122e84cd17dae1cab5c7dfb9043f1ee4f0a206",
"dmsg": {
"discovery": "http://dmsgd.skywire.skycoin.com",
"sessions_count": 1,
@@ -682,8 +687,8 @@ $ sudo skywire-cli config gen -bipr
"db_path": "/opt/skywire/users.db",
"enable_auth": true,
"cookies": {
- "hash_key": "8c180bfdeaaa39452858135d1abc2194d80af834bd2bed32d765e6190471e738f2fe0a44cdeffdf03b6414a58eae8ed3c2d3f8c97e2b00929dd50fa5b4f253f6",
- "block_key": "f88973dc329d770701b9cee3e9fc3a45c76099e3f1f6c83642b0a0d1f8f170ff",
+ "hash_key": "80b9c82cff3280592ca91e9f3d276f4b7c900551a24ef4f311567d21ad19d63dbdda75d3cbcce24863124151ba6d07846def16cb300cd2bd87117e802c743ac4",
+ "block_key": "d113be28b2a4b256dafde1598651b0f402b27912fb38b8449ba0b9a6c947775c",
"expires_duration": 43200000000000,
"path": "/",
"domain": ""
@@ -695,52 +700,29 @@ $ sudo skywire-cli config gen -bipr
"tls_key_file": "./ssl/key.pem"
}
}
-
```
The configuration is written (or rewritten)
-##### Example visor configuration for package based installation
+##### Example remote hypervisor configuration for package based installation
The typical arrangement uses a remote hypervisor if a local instance is not started.
-The hypervisor public key can be determined by running the following command on the running hypervisor
+The hypervisor public key can be determined by running the following command on the running hypervisor:
```
$ skywire-cli visor pk
```
-When running a visor with or without a hypervisor on the same machine, it's wise to keep the same keys for any persistent
-configuration.
-
-Copy the `skywire.json` config file from the previous example to `skywire-visor.json`; then paste the public key from
-the above command output into the following command
+configure the visor to use the public key of the remote hypervisor:
```
-# cp /opt/skywire/skywire.json /opt/skywire/skywire-visor.json
-# skywire-cli config gen -j -bpr -o /opt/skywire/skywire-visor.json
+# skywire-cli config gen -bprj
```
The configuration is regenerated
-##### Example running with systemd service integration
-
-The configuration files described above are specified in corresponding systemd service files in the skywire-bin .deb and archlinux packages to manage a visor or hypervisor instance
-
-hypervisor
-
-```
-# skywire-visor -c /opt/skywire/skywire.json
-```
-
-
-with remote hypervisor
-
-```
-# skywire-visor -c /opt/skywire/skywire-visor.json
-```
-
#### config update
```
@@ -766,7 +748,7 @@ Flags:
--set-minhop int change min hops value (default -1)
-i, --input string path of input config file.
-o, --output string config file to output
- -p, --pkg read from /opt/skywire/skywire.json
+ -u, --user update config at: $HOME/skywire-config.json
-h, --help help for update
Use "skywire-cli config update [command] --help" for more information about a command.
@@ -783,11 +765,11 @@ skywire-cli config update
```
$ skywire-cli config update
-[2022-04-02T18:47:15-05:00] INFO [visor:config]: Flushing config to file. config_version="0.6.0" filepath="/home/user/go/src/github.com/skycoin/skywire/skywire-config.json"
-[2022-04-02T18:47:15-05:00] INFO [skywire-cli]: Updated file '/home/user/go/src/github.com/skycoin/skywire/skywire-config.json' to: {
- "version": "0.6.0",
- "sk": "745badae7d125b90e3fd840b1d03d8a73565a3e0e976db6169b2d9368af86029",
- "pk": "037b000c6262694c0d2b5d64480c1d82a5a1597a80deab881443742359601bc6e6",
+[2022-05-26T17:58:16-05:00] INFO [visor:config]: Flushing config to file. config_version="v1.0.0" filepath="/home/user/go/src/github.com/skycoin/skywire/skywire-config.json"
+[2022-05-26T17:58:16-05:00] INFO [skywire-cli]: Updated file '/home/user/go/src/github.com/skycoin/skywire/skywire-config.json' to: {
+ "version": "v1.0.0",
+ "sk": "754ee10a20f8bc824c8c2ac9c6b26ab10112e0a339681bc759ccf87d714195a0",
+ "pk": "02bc601c45633f98da260946936b409ee098609f1192ff2b88986308f100edb721",
"dmsg": {
"discovery": "http://dmsgd.skywire.skycoin.com",
"sessions_count": 1,
@@ -1009,16 +991,16 @@ $ skywire-cli visor info
```
$ skywire-cli visor info
.:: Visor Summary ::.
-Public key: "034b68c4d8ec6d934d3ecb28595fea7e89a8de2048f0f857759c5018cb8e2f9525"
+Public key: "03caa7c5ea048c8200538ff81f53ffad08cc289f280f2cfce9c261ea8b03405097"
Symmetric NAT: false
IP: 192.168.0.2
DMSG Server: "0371ab4bcff7b121f4b91f6856d6740c6f9dc1fe716977850aeb5d84378b300a13"
-Ping: "451.449714ms"
-Visor Version: v0.6.0
+Ping: "447.072621ms"
+Visor Version: 1.0.0
Skybian Version:
Uptime Tracker: healthy
-Time Online: 37102.342894 seconds
-Build Tag: linux_amd64
+Time Online: 6082.307143 seconds
+Build Tag:
```
@@ -1034,7 +1016,7 @@ $ skywire-cli visor version
```
$ skywire-cli visor version
-Version "v0.6.0" built on "2022-02-17T11:18:39Z" against commit "b8b70310"
+Version "v1.0.0" built on "2022-05-26T18:18:39Z" against commit "668d5ad8"
```
#### app
@@ -1141,7 +1123,8 @@ $ skywire-cli visor app logs
##### Example
```
-$ skywire-cli visor app log skysocks beginning [2022-03-11T21:15:55-06:00] INFO [public_autoconnect]: Fetching public visors
+$ skywire-cli visor app log skysocks beginning
+ [2022-03-11T21:15:55-06:00] INFO [public_autoconnect]: Fetching public visors
[2022-03-11T21:16:06-06:00] INFO [public_autoconnect]: Fetching public visors
[2022-03-11T21:16:09-06:00] INFO [dmsgC]: Session stopped. error="failed to serve dialed session to 0371ab4bcff7b121f4b91f6856d6740c6f9dc1fe716977850aeb5d84378b300a13: EOF"
[2022-03-11T21:16:09-06:00] WARN [dmsgC]: Stopped accepting streams. error="EOF" session=0371ab4bcff7b121f4b91f6856d6740c6f9dc1fe716977850aeb5d84378b300a13
diff --git a/cmd/skywire-visor/README.md b/cmd/skywire-visor/README.md
index f49d5d5156..5cd4d0e493 100644
--- a/cmd/skywire-visor/README.md
+++ b/cmd/skywire-visor/README.md
@@ -3,10 +3,8 @@
- [Install](#install)
- [skywire-visor usage](#skywire-visor-usage)
+ - [flags](#skywire-visor-flags)
- [config file generation](#config-file-generation)
- - [Run from source without compiling](#run-from-source-without-compiling)
- - [Example running from source dir](#example-running-from-source-dir)
- - [Example package based installation](#example-package-based-installation)
@@ -39,272 +37,63 @@ Usage:
skywire-visor [flags]
Flags:
- -c, --config string config file to use default: skywire-config.json
- -i, --hvui run as hypervisor
+ -c, --config string config file to use (default): skywire-config.json
-b, --browser open hypervisor ui in default web browser
+ -i, --hvui run as hypervisor
+ -u, --user use config at: $HOME/skywire-config.json
--all show all flags
-h, --help help for skywire-visor
-v, --version version for skywire-visor
$ skywire-visor --all
+ ┌─┐┬┌─┬ ┬┬ ┬┬┬─┐┌─┐
+ └─┐├┴┐└┬┘││││├┬┘├┤
+ └─┘┴ ┴ ┴ └┴┘┴┴└─└─┘
- ┌─┐┬┌─┬ ┬┬ ┬┬┬─┐┌─┐
- └─┐├┴┐└┬┘││││├┬┘├┤
- └─┘┴ ┴ ┴ └┴┘┴┴└─└─┘
-
-Usage:
- skywire-visor [flags]
-
-Flags:
- -c, --config string config file to use default: skywire-config.json
- -i, --hvui run as hypervisor
- -b, --browser open hypervisor ui in default web browser
- -j, --hv string add remote hypervisor PKs at runtime
- -k, --xhv disable remote hypervisors set in config file
- -n, --stdin read config from stdin
- --ph use package config /opt/skywire/skywire.json
- --pv use package config /opt/skywire/skywire-visor.json
- -p, --pprofmode string pprof mode: cpu, mem, mutex, block, trace, http
- -q, --pprofaddr string pprof http port (default "localhost:6060")
- -t, --tag string logging tag (default "skywire")
- -y, --syslog string syslog server address. E.g. localhost:514
- -z, --completion string [ bash | zsh | fish | powershell ]
- -h, --help help for skywire-visor
- -v, --version version for skywire-visor
-```
+ Usage:
+ skywire-visor [flags]
-## Config file generation
-
-Refer to the [skywire-cli documentation](../skywire-cli/README.md) for more detailed information regarding additional flags and argument that may be passed to the following command:
+ Flags:
+ -b, --browser open hypervisor ui in default web browser
+ -c, --config string config file to use (default): skywire-config.json
+ -i, --hvui run as hypervisor
+ -j, --hv string add remote hypervisor PKs at runtime
+ -k, --xhv disable remote hypervisors set in config file
+ -n, --stdin read config from stdin
+ -p, --pkg use package config /opt/skywire/skywire.json
+ -q, --pprofmode string pprof mode: cpu, mem, mutex, block, trace, http
+ -r, --pprofaddr string pprof http port (default "localhost:6060")
+ -t, --tag string logging tag (default "skywire")
+ -u, --user use config at: $HOME/skywire-config.json
+ -y, --syslog string syslog server address. E.g. localhost:514
+ -z, --completion string [ bash | zsh | fish | powershell ]
+ -h, --help help for skywire-visor
+ -v, --version version for skywire-visor
```
-skywire-cli config gen
-```
-
-With no additional flags or arguments, the configuration is written to skywire-config.json and stdout.
-
-## Run from source without compiling
-
-The bin_path field in the visor config specifies the path where the binaries are called by skywire-visor. default `./apps`
-
-By placing scripts at this paths with the name of the binary, it is possible to run skywire from source without compiling.
-An example of the script
+### Skywire visor flags
-```
-#!/bin/bash
-go run ../../cmd/apps/skychat/chat.go
-```
+Mutually exclusive flags:
-The following runs skywire from source without compiling:
+* ` -n, --stdin`
+* ` -c, --config`
+* ` -p, --pkg`
+ - requires sudo / root permissions
+ - only shown when the config file exists
+* ` -u, --user`
+ - requires user permissions
+ - only shown when the config file exists
-```
-$ ln -sf scripts/_apps apps
-$ chmod +x apps/*
-$ go run cmd/skywire-cli/skywire-cli.go config gen -ibr skywire-config.json
-$ go run cmd/skywire-visor/skywire-visor.go -c skywire-config.json
-```
+The ` -b, --browser` flag is not available to root / with sudo.
-Or, with make:
-
-```
-make run-source
-```
-
-## Run from source without compiling or writing config
-
-Its possible to output the config from skywire-cli to stdout and pipe the config to skywire-visor as stdin
-
-```
-go run cmd/skywire-cli/skywire-cli.go config gen -ibn | go run cmd/skywire-visor/skywire-visor.go -nb
-```
-
-Useful for testing both skywire-cli and skywire-visor providing a single line to the shell.
-The config is not written to file in the above example
-
-
-##### Example running from source dir
-
-The default filename and paths in the skywire-config.json file are designed for the context of running skywire-visor from within the cloned source repository, wherever it may reside. A brief example of the terminal ouput when running skywire-visor where skywire-config.json exists in the current directory:
-
-```
-$ skywire-visor -c skywire-config.json
-[2022-02-07T18:49:00-06:00] DEBUG []: Process info build_tag="" delay=0s parent_systemd=false skybian_build_version="" systemd=false
-Version "unknown" built on "unknown" against commit "unknown"
-[2022-02-07T18:49:00-06:00] INFO [visor:config]: Reading config from file. filepath="skywire-config.json"
-[2022-02-07T18:49:00-06:00] INFO [visor:config]: Flushing config to file. config_version="v1.1.0" filepath="skywire-config.json"
-[2022-02-07T18:49:00-06:00] INFO [visor:startup]: Begin startup. public_key=02da35804dd25dbb91e64e64ca43336206538a775054702d2e543299e5168660ef
-[2022-02-07T18:49:00-06:00] INFO [hypervisor]: Starting
-[2022-02-07T18:49:00-06:00] INFO [visor]: Starting
-[2022-02-07T18:49:00-06:00] INFO [transports]: Starting
-[2022-02-07T18:49:00-06:00] INFO [router]: Starting
-[2022-02-07T18:49:00-06:00] INFO [cli]: Starting
-[2022-02-07T18:49:00-06:00] INFO [updater]: Starting
-[2022-02-07T18:49:00-06:00] INFO [dmsg_ctrl]: Starting
-[2022-02-07T18:49:00-06:00] INFO [stcpr]: Starting
-[2022-02-07T18:49:00-06:00] INFO [public_visor]: Starting
-[2022-02-07T18:49:00-06:00] INFO [public_autoconnect]: Starting
-[2022-02-07T18:49:00-06:00] INFO [transport_setup]: Starting
-[2022-02-07T18:49:00-06:00] INFO [discovery]: Starting
-[2022-02-07T18:49:00-06:00] INFO [stcp]: Starting
-[2022-02-07T18:49:00-06:00] INFO [address_resolver]: Starting
-[2022-02-07T18:49:00-06:00] INFO [dmsg_pty]: Starting
-[2022-02-07T18:49:00-06:00] INFO [hypervisors]: Starting
-[2022-02-07T18:49:00-06:00] INFO [uptime_tracker]: Starting
-[2022-02-07T18:49:00-06:00] INFO [transport]: Starting
-[2022-02-07T18:49:00-06:00] INFO [launcher]: Starting
-[2022-02-07T18:49:00-06:00] INFO [event_broadcaster]: Starting
-[2022-02-07T18:49:00-06:00] INFO [event_broadcaster]: Initialized in 2.929µs (3.236µs with dependencies)
-[2022-02-07T18:49:00-06:00] INFO [stun_client]: Starting
-[2022-02-07T18:49:00-06:00] INFO [sudph]: Starting
-[2022-02-07T18:49:00-06:00] INFO [dmsg_http]: Starting
-[2022-02-07T18:49:00-06:00] INFO [dmsg_http]: Initialized in 551ns (797ns with dependencies)
-[2022-02-07T18:49:00-06:00] INFO [dmsg]: Starting
-[2022-02-07T18:49:00-06:00] INFO [updater]: Initialized in 1.984µs (2.375µs with dependencies)
-[2022-02-07T18:49:00-06:00] INFO [dmsgC]: Discovering dmsg servers...
-[2022-02-07T18:49:00-06:00] INFO [discovery]: Initialized in 33.548µs (713.928µs with dependencies)
-[2022-02-07T18:49:00-06:00] INFO [address_resolver]: Remote UDP server: "ar.skywire.skycoin.com:30178"
-[2022-02-07T18:49:00-06:00] INFO [dmsg]: Initialized in 62.689µs (66.823µs with dependencies)
-[2022-02-07T18:49:00-06:00] INFO [hypervisors]: Initialized in 989ns (762.642µs with dependencies)
-[2022-02-07T18:49:00-06:00] INFO [dmsg_pty]: Initialized in 158.188µs (1.009816ms with dependencies)
-[2022-02-07T18:49:00-06:00] INFO [cli]: Initialized in 1.829639ms (1.829877ms with dependencies)
-[2022-02-07T18:49:01-06:00] INFO [uptime_tracker]: Initialized in 432.529335ms (432.952838ms with dependencies)
-[2022-02-07T18:49:01-06:00] INFO [dmsgC]: Dialing session... remote_pk=02347729662a901d03f1a1ab6c189a173349fa11e79fe82117cca0f8d0e4d64a31
-[2022-02-07T18:49:01-06:00] INFO [address_resolver]: Connected to address resolver. STCPR/SUDPH services are available.
-[2022-02-07T18:49:01-06:00] INFO [address_resolver]: Initialized in 987.461316ms (988.050386ms with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [dmsgC]: Serving session. remote_pk=02347729662a901d03f1a1ab6c189a173349fa11e79fe82117cca0f8d0e4d64a31
-[2022-02-07T18:49:02-06:00] INFO [transport]: Initialized in 470.128967ms (1.458111681s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [dmsgC]: Connecting to the dmsg network... timeout=20s
-[2022-02-07T18:49:02-06:00] INFO [transport_manager]: transport manager is serving.
-[2022-02-07T18:49:02-06:00] INFO [transport_setup]: Connecting to the dmsg network. local_pk=02da35804dd25dbb91e64e64ca43336206538a775054702d2e543299e5168660ef
-[2022-02-07T18:49:02-06:00] INFO [transport_setup]: Connected! local_pk=02da35804dd25dbb91e64e64ca43336206538a775054702d2e543299e5168660ef
-[2022-02-07T18:49:02-06:00] INFO [transport_setup]: starting listener dmsg_port=47
-[2022-02-07T18:49:02-06:00] INFO [transport_setup]: Accepting dmsg streams. dmsg_port=47
-[2022-02-07T18:49:02-06:00] INFO [transport_manager]: Serving stcp network
-[2022-02-07T18:49:02-06:00] INFO [transport_manager]: listening on network: stcp
-[2022-02-07T18:49:02-06:00] INFO [stcp]: Initialized in 366.457µs (1.458857374s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [transport_setup]: Initialized in 361.602µs (1.458985676s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [transport_manager]: Serving stcpr network
-[2022-02-07T18:49:02-06:00] INFO [transport_manager]: listening on network: stcpr
-[2022-02-07T18:49:02-06:00] INFO [stcp]: listening on addr: [::]:7777
-[2022-02-07T18:49:02-06:00] INFO [public_autoconnect]: Initialized in 9.502µs (1.458628811s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [router]: Starting router
-[2022-02-07T18:49:02-06:00] INFO [dmsgC]: Connected to the dmsg network. timeout=20s
-[2022-02-07T18:49:02-06:00] INFO [transport_manager]: Serving dmsg network
-[2022-02-07T18:49:02-06:00] INFO [transport_manager]: listening on network: dmsg
-[2022-02-07T18:49:02-06:00] INFO [stcpr]: Not binding STCPR: no public IP address found
-[2022-02-07T18:49:02-06:00] INFO [dmsg_ctrl]: Initialized in 696.857µs (1.459423545s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [router]: Initialized in 642.448µs (1.459665206s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [stcpr]: Initialized in 447.316µs (1.459153332s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [public_visor]: Initialized in 787ns (1.459423411s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [launcher]: Initialized in 21.113327ms (1.480061107s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [visor]: Initialized in 226ns (1.502320595s with dependencies)
-[2022-02-07T18:49:02-06:00] INFO [visor]: Initializing hypervisor
-[2022-02-07T18:49:02-06:00] INFO [visor]: Serving RPC client over dmsg. addr=02da35804dd25dbb91e64e64ca43336206538a775054702d2e543299e5168660ef:46
-[2022-02-07T18:49:02-06:00] INFO [visor]: Serving hypervisor... addr=":8000" tls=false
-[2022-02-07T18:49:02-06:00] INFO [visor]: Hypervisor initialized
-[2022-02-07T18:49:02-06:00] INFO [hypervisor]: Initialized in 19.833078ms (1.526147062s with dependencies)
-```
-
-##### Example for package based installation
-
-Assuming that skywire is installed to /opt/skywire; with app binaries installed at /opt/skywire/apps and the main skywire binaries directly in or symlinked to the executable path. All files generated by running skywire-visor should populate in /opt/skywire
-
-The configuration file is generated in the following way
-
-for a visor with local hypervisor:
-
-```
-$ skywire-cli config gen -bipr -o /opt/skywire/skywire.json
-```
+## Config file generation
-for visor with remote hypervisor; first copy the existing configuration file to keep the same keys.
+Refer to the [skywire-cli documentation](../skywire-cli/README.md) for more detailed information regarding additional flags and argument that may be passed to the following command:
```
-# cp /opt/skywire/skywire.json /opt/skywire/skywire-visor.json
-# skywire-cli config gen -bpj -o /opt/skywire/skywire-visor.json
+skywire-cli config gen
```
-These two configuration files are referenced in systemd service files to start skywire with either a local or remote hypervisor.
-
-To clarify some terminology; a 'visor' is a running instance of skywire-visor. Previously, on the testnet, this was called a 'node'. This was changed for the sake of differentiating the hardware from the software when troubleshooting issues. The 'public key' in the configuration file is referred to as the 'visor key' or the visor's public key. In the context of using a visor which is running a hypervisor instance as a remote hypervisor for another visor, the public key (visor key) of the visor running the hypervisor web instance is referred to as the 'hypervisor key' or the hypervisor's public key. A hypervisor key is a visor key, these terms are used interchangeably and refer to the same thing for a visor running a hypervisor instance.
-
-```
-# skywire -c /opt/skywire/skywire.json
-[2022-02-07T18:54:55-06:00] DEBUG []: Process info build_tag="linux_amd64" delay=0s parent_systemd=false skybian_build_version="" systemd=false
-Version "v0.6.0-rc1" built on "2022-02-04T13:58:58Z" against commit "74fde018"
-[2022-02-07T18:54:55-06:00] INFO [visor:config]: Reading config from file. filepath="/opt/skywire/skywire.json"
-[2022-02-07T18:54:55-06:00] INFO [visor:config]: Flushing config to file. config_version="v1.1.0" filepath="/opt/skywire/skywire.json"
-[2022-02-07T18:54:55-06:00] INFO [visor:startup]: Begin startup. public_key=027087fe40d97f7f0be4a0dc768462ddbb371d4b9e7679d4f11f117d757b9856ed
-[2022-02-07T18:54:55-06:00] INFO [hypervisor]: Starting
-[2022-02-07T18:54:55-06:00] INFO [visor]: Starting
-[2022-02-07T18:54:55-06:00] INFO [stcpr]: Starting
-[2022-02-07T18:54:55-06:00] INFO [transport]: Starting
-[2022-02-07T18:54:55-06:00] INFO [launcher]: Starting
-[2022-02-07T18:54:55-06:00] INFO [updater]: Starting
-[2022-02-07T18:54:55-06:00] INFO [public_visor]: Starting
-[2022-02-07T18:54:55-06:00] INFO [stcp]: Starting
-[2022-02-07T18:54:55-06:00] INFO [address_resolver]: Starting
-[2022-02-07T18:54:55-06:00] INFO [updater]: Initialized in 3.209µs (3.578µs with dependencies)
-[2022-02-07T18:54:55-06:00] INFO [router]: Starting
-[2022-02-07T18:54:55-06:00] INFO [dmsg_http]: Starting
-[2022-02-07T18:54:55-06:00] INFO [dmsg_http]: Initialized in 720ns (981ns with dependencies)
-[2022-02-07T18:54:55-06:00] INFO [discovery]: Starting
-[2022-02-07T18:54:55-06:00] INFO [discovery]: Initialized in 13.829µs (15.098µs with dependencies)
-[2022-02-07T18:54:55-06:00] INFO [dmsg_pty]: Starting
-[2022-02-07T18:54:55-06:00] INFO [uptime_tracker]: Starting
-[2022-02-07T18:54:55-06:00] INFO [transports]: Starting
-[2022-02-07T18:54:55-06:00] INFO [dmsg_ctrl]: Starting
-[2022-02-07T18:54:55-06:00] INFO [event_broadcaster]: Starting
-[2022-02-07T18:54:55-06:00] INFO [sudph]: Starting
-[2022-02-07T18:54:55-06:00] INFO [dmsg]: Starting
-[2022-02-07T18:54:55-06:00] INFO [transport_setup]: Starting
-[2022-02-07T18:54:55-06:00] INFO [public_autoconnect]: Starting
-[2022-02-07T18:54:55-06:00] INFO [cli]: Starting
-[2022-02-07T18:54:55-06:00] INFO [address_resolver]: Remote UDP server: "ar.skywire.skycoin.com:30178"
-[2022-02-07T18:54:55-06:00] INFO [stun_client]: Starting
-[2022-02-07T18:54:55-06:00] INFO [hypervisors]: Starting
-[2022-02-07T18:54:55-06:00] INFO [event_broadcaster]: Initialized in 2.329µs (2.548µs with dependencies)
-[2022-02-07T18:54:55-06:00] INFO [dmsg]: Initialized in 22.794µs (367.528µs with dependencies)
-[2022-02-07T18:54:55-06:00] INFO [hypervisors]: Initialized in 915ns (85.737µs with dependencies)
-[2022-02-07T18:54:55-06:00] INFO [dmsgC]: Discovering dmsg servers...
-[2022-02-07T18:54:55-06:00] INFO [dmsg_pty]: Initialized in 54.266µs (656.963µs with dependencies)
-[2022-02-07T18:54:55-06:00] INFO [cli]: Initialized in 404.237µs (404.515µs with dependencies)
-[2022-02-07T18:54:55-06:00] INFO [dmsgC]: Dialing session... remote_pk=02347729662a901d03f1a1ab6c189a173349fa11e79fe82117cca0f8d0e4d64a31
-[2022-02-07T18:54:55-06:00] INFO [uptime_tracker]: Initialized in 509.132965ms (509.13433ms with dependencies)
-[2022-02-07T18:54:55-06:00] INFO [address_resolver]: Connected to address resolver. STCPR/SUDPH services are available.
-[2022-02-07T18:54:56-06:00] INFO [address_resolver]: Initialized in 1.03416369s (1.034390128s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [dmsgC]: Serving session. remote_pk=02347729662a901d03f1a1ab6c189a173349fa11e79fe82117cca0f8d0e4d64a31
-[2022-02-07T18:54:56-06:00] INFO [transport]: Initialized in 507.868374ms (1.542672709s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [transport_manager]: Serving stcpr network
-[2022-02-07T18:54:56-06:00] INFO [transport_manager]: transport manager is serving.
-[2022-02-07T18:54:56-06:00] INFO [transport_setup]: Connecting to the dmsg network. local_pk=027087fe40d97f7f0be4a0dc768462ddbb371d4b9e7679d4f11f117d757b9856ed
-[2022-02-07T18:54:56-06:00] INFO [transport_setup]: Connected! local_pk=027087fe40d97f7f0be4a0dc768462ddbb371d4b9e7679d4f11f117d757b9856ed
-[2022-02-07T18:54:56-06:00] INFO [transport_manager]: listening on network: stcpr
-[2022-02-07T18:54:56-06:00] INFO [transport_setup]: starting listener dmsg_port=47
-[2022-02-07T18:54:56-06:00] INFO [stcpr]: Initialized in 471.448µs (1.543308565s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [transport_setup]: Accepting dmsg streams. dmsg_port=47
-[2022-02-07T18:54:56-06:00] INFO [stcpr]: Not binding STCPR: no public IP address found
-[2022-02-07T18:54:56-06:00] INFO [transport_manager]: Serving stcp network
-[2022-02-07T18:54:56-06:00] INFO [transport_manager]: listening on network: stcp
-[2022-02-07T18:54:56-06:00] INFO [transport_setup]: Initialized in 481.348µs (1.542390746s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [public_visor]: Initialized in 641ns (1.543038283s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [dmsgC]: Connecting to the dmsg network... timeout=20s
-[2022-02-07T18:54:56-06:00] INFO [dmsgC]: Connected to the dmsg network. timeout=20s
-[2022-02-07T18:54:56-06:00] INFO [transport_manager]: Serving dmsg network
-[2022-02-07T18:54:56-06:00] INFO [public_autoconnect]: Initialized in 67.16µs (1.542018866s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [router]: Starting router
-[2022-02-07T18:54:56-06:00] INFO [router]: Initialized in 926.371µs (1.543240321s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [stcp]: Initialized in 590.35µs (1.54314418s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [stcp]: listening on addr: [::]:7777
-[2022-02-07T18:54:56-06:00] INFO [transport_manager]: listening on network: dmsg
-[2022-02-07T18:54:56-06:00] INFO [dmsg_ctrl]: Initialized in 1.011469ms (1.543159903s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [launcher]: Initialized in 12.681013ms (1.556420507s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [visor]: Initialized in 245ns (1.566227368s with dependencies)
-[2022-02-07T18:54:56-06:00] INFO [visor]: Initializing hypervisor
-[2022-02-07T18:54:56-06:00] INFO [visor]: Serving RPC client over dmsg. addr=027087fe40d97f7f0be4a0dc768462ddbb371d4b9e7679d4f11f117d757b9856ed:46
-[2022-02-07T18:54:56-06:00] INFO [visor]: Serving hypervisor... addr=":8000" tls=false
-[2022-02-07T18:54:56-06:00] INFO [visor]: Hypervisor initialized
-[2022-02-07T18:54:56-06:00] INFO [hypervisor]: Initialized in 42.392586ms (1.616936619s with dependencies)
-```
+With no additional flags or arguments, the configuration is written to skywire-config.json and stdout.