Browse Source

updated ConfigurationFiles.md

pull/583/head
Logan oos Even 4 years ago
committed by GitHub
parent
commit
7d918c4da2
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 38
      doc/ConfigurationFiles.md

38
doc/ConfigurationFiles.md

@ -1,6 +1,6 @@
# Configuration Files # Configuration Files
To help deployment of locally different configurations, n2n supports the use of configuration files for `edge` and `supernode`. To help deployment and better handle locally different configurations, n2n supports the optional use of configuration files for `edge` and `supernode`.
They are plain text files and contain the desired command line options, **one per line**. They are plain text files and contain the desired command line options, **one per line**.
@ -18,6 +18,7 @@ translates into the following `edge.conf` file:
-a 192.168.100.1 -a 192.168.100.1
-f -f
-l supernode.ntop.org:7777 -l supernode.ntop.org:7777
-A5
``` ```
which can be loaded by which can be loaded by
@ -26,18 +27,6 @@ which can be loaded by
sudo ./edge edge.conf sudo ./edge edge.conf
``` ```
The `.conf` file syntax also allows `=` between parameter and its option:
```
-c=mynetwork
-k=mysecretpass
-a=192.168.100.1
-f
-l=supernode.ntop.org:7777
```
When used with `=`, there is no whitespace allowed between parameter, delimter (`=`), and option. So, do **not** put `-c = mynetwork` – it is required to be `-c=mynetwork`.
Comment lines starting with a hash '#' are ignored. Comment lines starting with a hash '#' are ignored.
``` ```
@ -48,26 +37,37 @@ Comment lines starting with a hash '#' are ignored.
-k mysecretpass -k mysecretpass
-a 192.168.100.1 -a 192.168.100.1
-f -f
-A5
# --- supernode section --- # --- supernode section ---
-l supernode.ntop.org:7777 -l supernode.ntop.org:7777
``` ```
Long options can be used as well. Please note the double minus/dash character `--`, just like on command line: Long options can be used as well. Please note the double minus/dash-character `--`, just like you would use them on the command line with long options:
``` ```
# automated edge configuration
# created by bot7
# on April 31, 2038 – 1800Z
--community mynetwork --community mynetwork
-k mysecretpass -k mysecretpass
-a 192.168.100.1 -a 192.168.100.1
-f -f
# --- supernode section --- -A5
-l supernode.ntop.org:7777 -l supernode.ntop.org:7777
``` ```
If using a configuration file, its filename needs to be supplied as first parameter to `edge` or `supernode`. If required, additional command line parameters can be supplied afterwards: If using a configuration file, its filename needs to be supplied as first parameter to `edge` or `supernode`. If required, additional command line parameters can be supplied afterwards:
``` ```
sudo edge edge.conf -A5 sudo edge edge.conf -z1 -I myComputer
``` ```
Finally, the `.conf` file syntax also allows `=` between parameter and its option:
```
-c=mynetwork
-k=mysecretpass
-a=192.168.100.1
-f
-A5
-l=supernode.ntop.org:7777
```
When used with `=`, there is no whitespace allowed between parameter, delimter (`=`), and option. So, do **not** put `-c = mynetwork` – it is required to be `-c=mynetwork`.

Loading…
Cancel
Save