diff --git a/config.go b/config.go index 2f62298..3fd72d8 100644 --- a/config.go +++ b/config.go @@ -3,7 +3,7 @@ * Author: Ming Cheng * * Created Date: Tuesday, June 21st 2022, 6:03:38 pm - * Last Modified: Thursday, July 7th 2022, 6:30:15 pm + * Last Modified: Tuesday, July 12th 2022, 1:45:52 pm * * http://www.opensource.org/licenses/MIT */ @@ -21,7 +21,7 @@ type ServerConfig struct { Sock5 struct { Addr string `yaml:"addr"` - } `yaml:"sock5"` + } `yaml:"socks5"` } type Configure struct { diff --git a/docker-compose.yaml b/docker-compose.yaml index b3dae0c..55dd9f1 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -6,4 +6,10 @@ services: image: ghcr.io/mingcheng/socks5lb environment: CHECK_TIME_INTERVAL: 60 + SELECT_TIME_INTERVAL: 120 + DEBUG: "true" + ports: + - 1080:1080 + volumes: + - ./socks5lb.yml:/etc/socks5lb.yml:ro restart: unless-stopped diff --git a/socks5lb.yml b/socks5lb.yml index 915f319..f051bd0 100644 --- a/socks5lb.yml +++ b/socks5lb.yml @@ -3,7 +3,7 @@ # Author: Ming Cheng # # Created Date: Wednesday, July 6th 2022, 2:26:10 pm -# Last Modified: Thursday, July 7th 2022, 6:32:10 pm +# Last Modified: Tuesday, July 12th 2022, 1:46:17 pm # # http://www.opensource.org/licenses/MIT ### @@ -12,9 +12,9 @@ server: http: addr: ":8080" socks5: - addr: ":1980" + addr: ":1080" tproxy: - addr: "" + addr: ":8848" backends: - addr: 192.168.100.254:1086 check_config: @@ -31,3 +31,13 @@ backends: check_url: https://twitter.com/robots.txt initial_alive: true timeout: 3 + - addr: host.docker.internal:1081 + check_config: + check_url: https://www.google.com/robots.txt + initial_alive: false + timeout: 6 + - addr: host.docker.internal:1082 + check_config: + check_url: https://www.google.com/robots.txt + initial_alive: false + timeout: 6