拨号主机设置
首先配置好代理,如使用 Squid,运行在 3128 端口,并设置好用户名和密码。
配置好代理之后,即可使用本工具定时拨号并发送至 Redis。
安装 ADSLProxy
pip3 install -U adslproxy-ota
设置环境变量
# Redis 数据库地址、端口和密码
export REDIS_HOST=
export REDIS_PORT=
export REDIS_PASSWORD=
# 拨号云主机配置的代理端口
export PROXY_PORT=
# 拨号云主机的代理用户名,无认证则留空
export PROXY_USERNAME=
# 拨号云主机配置的代理密码,无认证则留空
export PROXY_PASSWORD=
执行
adslproxy send
运行结果:
运行结果:
2020-04-13 01:39:30.811 | INFO | adslproxy.sender.sender:loop:90 - Starting dial...
2020-04-13 01:39:30.812 | INFO | adslproxy.sender.sender:run:99 - Dial Started, Remove Proxy
2020-04-13 01:39:30.812 | INFO | adslproxy.sender.sender:remove_proxy:62 - Removing adsl1...
2020-04-13 01:39:30.893 | INFO | adslproxy.sender.sender:remove_proxy:69 - Removed adsl1 successfully
2020-04-13 01:39:37.034 | INFO | adslproxy.sender.sender:run:108 - Get New IP 113.128.9.239
2020-04-13 01:39:42.221 | INFO | adslproxy.sender.sender:run:117 - Valid proxy 113.128.9.239:3389
2020-04-13 01:39:42.458 | INFO | adslproxy.sender.sender:set_proxy:82 - Successfully Set Proxy
2020-04-13 01:43:02.560 | INFO | adslproxy.sender.sender:loop:90 - Starting dial...
2020-04-13 01:43:02.561 | INFO | adslproxy.sender.sender:run:99 - Dial Started, Remove Proxy
2020-04-13 01:43:02.561 | INFO | adslproxy.sender.sender:remove_proxy:62 - Removing adsl1...
2020-04-13 01:43:02.630 | INFO | adslproxy.sender.sender:remove_proxy:69 - Removed adsl1 successfully
2020-04-13 01:43:08.770 | INFO | adslproxy.sender.sender:run:108 - Get New IP 113.128.31.230
2020-04-13 01:43:13.955 | INFO | adslproxy.sender.sender:run:117 - Valid proxy 113.128.31.230:3389
2020-04-13 01:43:14.037 | INFO | adslproxy.sender.sender:set_proxy:82 - Successfully Set Proxy
2020-04-13 01:46:34.216 | INFO | adslproxy.sender.sender:loop:90 - Starting dial...
2020-04-13 01:46:34.217 | INFO | adslproxy.sender.sender:run:99 - Dial Started, Remove Proxy
2020-04-13 01:46:34.217 | INFO | adslproxy.sender.sender:remove_proxy:62 - Removing adsl1...
2020-04-13 01:46:34.298 | INFO | adslproxy.sender.sender:remove_proxy:69 - Removed adsl1 successfully
此时有效代理就会发送到 Redis。
Metadata
Release files for adslproxy-ota 1.0.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| adslproxy-ota-1.0.4.tar.gz | 8.3 kB | Without provenance | Details |
Release files / adslproxy-ota-1.0.4.tar.gz
| Download URL | adslproxy-ota-1.0.4.tar.gz |
|---|---|
| Size | 8.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f53a70ac6da169232d37d1ca8a24a713b5e14f9ccd042b7a7c054b318805ace0
|
|
BLAKE2b-256 checksum How to use checksums |
fd9b72298b8a7ca277cadd9fa14a6670dd243d1138261e50643ebd174fdb156d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.5.0.1 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.7.6
|
Security for adslproxy-ota 1.0.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.