From 37489ea01e87e38b31b3e1e187f22d624bb29049 Mon Sep 17 00:00:00 2001 From: Samuel Huang Date: Fri, 24 Sep 2021 21:55:59 +1000 Subject: [PATCH] README.md --- README.md | 17 +++++++++-------- run.sh | 4 ++-- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 68c8f95..b0513f1 100644 --- a/README.md +++ b/README.md @@ -70,8 +70,8 @@ server-xray --ttt [p=443,]d=domain.com,u=psw[:level[:email]][,f=[fb-host]:fb-port:[fb-path]] --tttw [p=443,]d=domain.com,u=psw[:level[:email]][,f=[fb-host]:fb-port:[fb-path]],w=/webpath --ttpw [p=443,]u=psw[:level[:email]][,f=[fb-host]:fb-port:[fb-path]],w=/webpath - --ng-opt [p=443,]d=domain0.com[,d=domain1.com] - --ng-proxy [d=domain0.com,][d=domain1.com][h=127.0.0.1,]p=port-backend,l=location,n=ws|grpc + --ng-opt [p=443,]d=domain0.com[,d=domain1.com...] + --ng-proxy [d=domain0.com,][d=domain1.com...][h=127.0.0.1,]p=port-backend,l=location,n=ws|grpc -u|--user u=id0[:level[:email]][,u=id1...] -k|--hook [Optional] DDNS update or notifing URL to be hit -r|--request-domain [Optional] Domain name to request for letsencrypt cert @@ -223,18 +223,19 @@ The following command will: 1. Assume to read TLS cert from /home/ubuntu/cert/domain*.duckdns.org/fullchain.cer 2. Assume to read private key from /home/ubuntu/cert/domain*.duckdns.org/domain*.duckdns.org.key 3. Assume domain0.duckdns.org and domain1.duckdns.org has been resolved to the current server -4. Run Vless+TCP+PLAN+gRPC service on port 55443, location /svc0, serve on all domains -5. Run Vless+TCP+PLAN+WebSocket service on port 53443, location /ws1, serve on all domains -6. Run Trojan+TCP+PLAN+WebSocket service on port 51443, location /ws2, serve only on domain1.duckdns.org +4. Run Vless+TCP+PLAN+gRPC service on port 55443, location /svc0, serve all domains +5. Run Vless+TCP+PLAN+WebSocket service on port 53443, location /ws1, serve all domains +6. Run Trojan+TCP+PLAN+WebSocket service on port 51443, location /ws2, serve only domain1.duckdns.org 7. Run nginx on port 443 as a TLS front with the given certs for 2 domains, proxy 3 services with 3 locations 8. Only port 443 will be available for access from internet ```shell -$ docker run --name server-xray -p 443:443 -v /home/ubuntu/cert:/opt/cert -d samuelhbne/server-xray -c /opt/cert \ +$ docker run --name server-xray -p 443:443 -v /home/ubuntu/cert:/opt/cert -d samuelhbne/server-xray \ +-c /opt/cert \ +--ng-opt p=443,d=domain0.duckdns.org,d=domain1.duckdns.org \ --ltpg p=55443,u=myid0,s=svc0 \ --ltpw p=53443,u=myid1,w=/ws1 \ --ttpw p=51443,u=myid2,w=/ws2 \ ---ng-opt p=443,d=domain0.duckdns.org,d=domain1.duckdns.org \ --ng-proxy p=55443,l=/svc0,n=grpc \ --ng-proxy p=53443,l=/ws1,n=ws \ --ng-proxy d=domain1.duckdns.org,p=51443,l=/ws2,n=ws @@ -263,7 +264,7 @@ $ curl -sSx socks5h://127.0.0.1:3080 http://ifconfig.co ... ``` -### 5. Running server-ray container in debug mode for connection issue diagnosis +### 5. Running server-xray container in debug mode for connection issue diagnosis The following instruction start server-trojan in debug mode. Output Xray config file and the log to console for connection diagnosis. diff --git a/run.sh b/run.sh index 9680cf0..5b81137 100755 --- a/run.sh +++ b/run.sh @@ -20,8 +20,8 @@ usage() { echo " --ttpw [p=443,]u=psw[:level[:email]][,f=[fb-host]:fb-port:[fb-path]],w=/webpath" # echo " --ssa [port=443,]user=password1:method1[,user=password2:method2]" # echo " --sst [port=443,]user=passwd,method=xxxx" - echo " --ng-opt [p=443,]d=domain0.com[,d=domain1.com]" - echo " --ng-proxy [d=domain0.com,][d=domain1.com][h=127.0.0.1,]p=port-backend,l=location,n=ws|grpc" + echo " --ng-opt [p=443,]d=domain0.com[,d=domain1.com...]" + echo " --ng-proxy [d=domain0.com,][d=domain1.com...][h=127.0.0.1,]p=port-backend,l=location,n=ws|grpc" echo " -u|--user u=id0[:level[:email]][,u=id1...]" echo " -k|--hook [Optional] DDNS update or notifing URL to be hit" echo " -r|--request-domain [Optional] Domain name to request for letsencrypt cert"