From 70522f851a1a65847b07dfd4d31079d75c56aa63 Mon Sep 17 00:00:00 2001 From: _ <> Date: Sun, 8 Nov 2020 02:36:27 +0000 Subject: [PATCH] Add module diagram --- README.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/README.md b/README.md index f08902f..ca0e78d 100644 --- a/README.md +++ b/README.md @@ -150,6 +150,35 @@ WireGuard can also pierce firewalls, but it requires root permissions, and the client must be a WireGuard node. PTTH allows any normal HTTP client such as curl, Firefox, etc. +## Module overview + +``` ++------------+ +-------------+ +------------------+ +| ptth_relay | | ptth_server | | ptth_file_server | ++------------+ +-------------+ +------------------+ + | | | | + \ / \ / + V V V V + +------------+ +-------------+ + | http_serde | | file_server | + +------------+ +-------------+ +``` + +The top-level binaries are ptth_relay, ptth_server, and ptth_file_server. + +ptth_relay should run on a well-known public server, behind an HTTPS proxy +such as Caddy, Nginx, or Apache. + +ptth_file_server is a standalone HTTP file server, similar to Python2's +`-m SimpleHTTPServer` command, or Python3's `-m http.server`. + +ptth_server and ptth_file_server use the `file_server` module. ptth_server +will connect out to a ptth_relay instance and serve files through the reverse +HTTP tunnel. + +The http_serde module is shared by ptth_relay and ptth_server so that they +can communicate with each other easily. + ## Why are GitHub issues disabled? Because they are not part of Git.