-
Notifications
You must be signed in to change notification settings - Fork 236
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[DOCs/operators]: Create a Nym ISP sheet, write gateway-probe guide &…
… clean FnF docs (#4590) * initialise nym versin of good-bad isps by tor community * syntax edit * finalise csv2md * initialise isp-list page * add last update info * add python3 plugis to ci/cd runnners * remove argparse installation * python3 syntax edit * pip install attempt * pip install attempt * change python version in cmdrun command * fix python modules installation * correct command python version * workflows python env update * add probe guide, clean FnF pages * fix typos
- Loading branch information
Showing
11 changed files
with
228 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,11 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install Dependencies (Linux) | ||
run: sudo apt-get update && sudo apt-get install -y build-essential curl wget libssl-dev libudev-dev squashfs-tools protobuf-compiler git | ||
run: sudo apt-get update && sudo apt-get install -y build-essential curl wget libssl-dev libudev-dev squashfs-tools protobuf-compiler git python3 && sudo apt-get update --fix-missing | ||
- name: Install pip3 | ||
run: sudo apt install -y python3-pip | ||
- name: Install Python3 modules | ||
run: sudo pip3 install pandas tabulate | ||
- name: Install rsync | ||
run: sudo apt-get install rsync | ||
- uses: rlespinasse/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,7 +13,11 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install Dependencies (Linux) | ||
run: sudo apt-get update && sudo apt-get install -y build-essential curl wget libssl-dev libudev-dev squashfs-tools protobuf-compiler git | ||
run: sudo apt-get update && sudo apt-get install -y build-essential curl wget libssl-dev libudev-dev squashfs-tools protobuf-compiler git python3 && sudo apt-get update --fix-missing | ||
- name: Install pip3 | ||
run: sudo apt install -y python3-pip | ||
- name: Install Python3 modules | ||
run: sudo pip3 install pandas tabulate | ||
- name: Install rsync | ||
run: sudo apt-get install rsync | ||
- uses: rlespinasse/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
**ISP**,**Locations**,**Public IPv6**,**Crypto Payments**,**Comments**,**Last Updated** | ||
[Flokinet](https://flokinet.is),"Netherlands, Iceland, Romania,France","Yes, needs a ticket and custom setup","yes, including XMR","Very slow customer support","05/2024" | ||
[BitLaunch](https://bitlaunch.io),"Canada, USA, UK","No","Yes","Expensive. Digial Ocean through BitLanch has IPv6","05/2024" | ||
[Hostinger](https://hostinger.com),"France, Lithuania, India, USA, Brazil","Yes, out of the box","Yes","Crypto payments must be done per each server monthly or annually.","05/2024" | ||
[Linode](https://linode.com),"USA, Canada, Japan, India, Indonesia, Sweden, Netherlands, Germany, Brazil, France, UK, Australia, Italy","Yes out of the box","No, only through [BitLAunch](https://bitlaunch.io)","IPv6 sometimes need to be re-added in Networking tab, no reboot needed","05/2024" | ||
[Cherry Servers](https://www.cherryservers.com),"Lithuania, Netherlands, USA, Singapore","No","Yes","Issued IP doesn’t match the location offered by the provider.","05/2024" | ||
[Njalla](https://nja.la),"Sweden","Yes","Yes","Privacy vandguards! The biggest VPS 45 is 3 cores only, but it works better than many “larger” servers on the market.","05/2024" | ||
[HostSailor](https://hostsailor.com),"USA","Yes, based on ticket","Yes","The IPv6 setup needs custom research and is not documented","05/2024" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# Where to host your `nym-node`? | ||
|
||
```admonish info | ||
The entire content of this page is under [Creative Commons Attribution 4.0 International Public License](https://creativecommons.org/licenses/by/4.0/). | ||
``` | ||
|
||
Inspired by a valuable resource, done by Tor community - [*Good Bad ISPs*](https://community.torproject.org/relay/community-resources/good-bad-isps/), LunarDAO squad initiated a table customised for Nym Exit Gateways operators. | ||
|
||
This ISP list is fully managed by Nym operator community and it serves as a space to share their experience of running Exit Gateways on various Internet Service Providers (ISPs). The ISPs greatly differ in regards to services they offer as well as to their openess of hosting exit routing software. | ||
|
||
Please share any experiences running a node like policies, complains, legal issues and solutions, discrepancy between offers and reality (bandwidth, IP range, locations) or anything regarding pricing or customer support. | ||
|
||
If you came across any legal findings, please share them in our [list of jurisdictions](jurisdictions.md). | ||
|
||
While we trust that Nym node operators are honest, we would like to ask everyone to do your own research. | ||
|
||
```admonish caution title="" | ||
To edit or add information to the ISP list, make changes to the csv file located [here](https://github.com/nymtech/nym/blob/develop/documentation/operators/src/data/isp-sheet.csv) and submit your edits as a pull request according to [this guide](add-content.md). | ||
``` | ||
|
||
```admonish note title="" | ||
As of now the list is quite short. When it grows, we can divide it according the localities of the listed ISPs. | ||
``` | ||
|
||
<!--cmdrun python3 ../../../scripts/csv2md.py ../data/isp-sheet.csv -s 0 --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
# Nym Gateway Probe | ||
|
||
Nym Node operators running Gateway functionality are already familiar with the monitoring tool [Harbourmaster.nymtech.net](https://harbourmaster.nymtech.net). Under the hood of Nym Harbourmaster runs iterations of `nym-gateway-probe` doing various checks and displaying the results on the interface. Operators don't have to rely on the probe ran by Nym and wait for the data to refresh. With `nym-gateway-probe` everyone can check any Gateway's networking status from their own computer at any time. In one command the client queries data from: | ||
|
||
- [`nym-api`](https://validator.nymtech.net/api/) | ||
- [`explorer-api`](https://explorer.nymtech.net/api/) | ||
- [`harbour-master`](https://harbourmaster.nymtech.net/) | ||
|
||
|
||
## Preparation | ||
|
||
We recommend to have install all [the prerequisites](../binaries/building-nym.md#prerequisites) needed to build `nym-node` from source including latest [Rust Toolchain](https://www.rust-lang.org/tools/install). | ||
|
||
## Installation | ||
|
||
`nym-gateway-probe` source code is in [`nym-vpn-client`](https://github.com/nymtech/nym-vpn-client) repository. The client needs to be build from source. | ||
|
||
1. Clone the repository: | ||
|
||
```sh | ||
git clone https://github.com/nymtech/nym-vpn-client.git | ||
``` | ||
|
||
2. Build `nym-gateway-probe`: | ||
|
||
```sh | ||
cd nym-vpn-client | ||
|
||
cargo build --release -p nym-gateway-probe | ||
``` | ||
|
||
## Running the client | ||
|
||
```sh | ||
./target/release/nym-gateway-probe --help | ||
``` | ||
~~~admonish collapsible=true | ||
``` | ||
Usage: nym-gateway-probe [OPTIONS] | ||
Options: | ||
-c, --config-env-file <CONFIG_ENV_FILE> Path pointing to an env file describing the network | ||
-g, --gateway <GATEWAY> | ||
-n, --no-log | ||
-h, --help Print help | ||
-V, --version Print version | ||
``` | ||
~~~ | ||
|
||
To run the client, simply add a flag `--gateway` with a targeted gateway identity key. | ||
|
||
```sh | ||
./target/release/nym-gateway-probe --gateway <GATEWAY_IDENTITY_KEY> | ||
``` | ||
|
||
For any `nym-node --mode exit-gateway` the aim is to have this outcome: | ||
```sh | ||
{ | ||
"gateway": "<GATEWAY_IDENTITY_KEY>", | ||
"outcome": { | ||
"as_entry": { | ||
"can_connect": true, | ||
"can_route": true | ||
}, | ||
"as_exit": { | ||
"can_connect": true, | ||
"can_route_ip_v4": true, | ||
"can_route_ip_external_v4": true, | ||
"can_route_ip_v6": true, | ||
"can_route_ip_external_v6": true | ||
} | ||
} | ||
} | ||
``` | ||
|
||
If you don't provide a `--gateway` flag it will pick a random one to test. | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
#!/usr/bin/python3 | ||
|
||
"""CLI to display .csv files as markdown""" | ||
|
||
import argparse | ||
import pandas as pd | ||
import sys | ||
import csv | ||
|
||
def create_table(args): | ||
"""Imports csv and creates a table""" | ||
file = args.file | ||
csv = pd.read_csv(file) | ||
if args.sort != None: | ||
csv = csv.sort_values(csv.columns[args.sort]) | ||
if args.table: | ||
table = csv.to_markdown(tablefmt="grid", index=args.index) | ||
else: | ||
table = csv.to_markdown(index=args.index) | ||
return table | ||
|
||
def display_file(args): | ||
"""Display csv file as a table""" | ||
table = create_table(args) | ||
print(table) | ||
|
||
def panic(msg): | ||
"""Error message print""" | ||
print(f"error: {msg}", file=sys.stderr) | ||
sys.exit(-1) | ||
|
||
def parser_main(): | ||
"""Main function initializing ArgumentParser, storing arguments and executing commands.""" | ||
# Top level parser | ||
parser = argparse.ArgumentParser( | ||
prog='CSV2MD', | ||
description='''Displays .csv files in markdown''', | ||
epilog='''Code is power!''' | ||
) | ||
|
||
# Parser arguments | ||
parser.add_argument("-V","--version", action="version", version='%(prog)s 1.1.0') | ||
parser.add_argument("file", help="path/to/file.csv") | ||
parser.add_argument("-t","--table", default=False, action="store_true", help="output with a tabulate option for terminal reading - does not render in mdbook") | ||
parser.add_argument("-i","--index", default=False, action="store_true", help="output with an index column") | ||
parser.add_argument("-s","--sort", type=int, help="supply with column index to sort your output accordingly (ascending way)") | ||
|
||
parser.set_defaults(func=display_file) | ||
args = parser.parse_args() | ||
|
||
try: | ||
args.func(args) | ||
except AttributeError as e: | ||
msg = f"{e}.\nPlease run with --help or read the error message in case your .csv file is corrupted." | ||
panic(msg) | ||
|
||
|
||
if __name__ == '__main__': | ||
parser_main() |