remove canihazip, adjust timing, adjust catbox test url

This commit is contained in:
Cyberes 2024-04-11 17:59:19 -06:00
parent 28c7b60271
commit da9c2b1635
6 changed files with 3 additions and 32 deletions

View File

@ -11,7 +11,7 @@ servers without worrying about implementing anything special clientside.
1. `pip install -r requirements.txt`
2. Copy `proxy-skeleton/app/config.py.example` to `proxy-skeleton/app/config.py` and fill in your config details.
3. Deploy the `./canihazip` directory and start the server.
3. Deploy the `canihazip` https://git.evulid.cc/cyberes/canihazip and start it.
## Use

View File

@ -1 +0,0 @@
A simple server to give the client his IP address. Used for the proxy load balancer.

View File

@ -1,14 +0,0 @@
[Unit]
Description=canihazip
After=network.target
[Service]
SyslogIdentifier=canihazip
User=flask
Group=nogroup
WorkingDirectory=/srv/canihazip
ExecStart=/srv/canihazip/venv/bin/gunicorn --workers 3 --bind 0.0.0.0:5000 server:app --timeout 120
Restart=always
[Install]
WantedBy=multi-user.target

View File

@ -1,14 +0,0 @@
from flask import Flask
from flask import request
app = Flask(__name__)
@app.route('/', defaults={'path': ''})
@app.route('/<path:path>')
def get_my_ip(path):
return request.remote_addr, 200
if __name__ == '__main__':
app.run(host="0.0.0.0", port=5000)

View File

@ -124,4 +124,4 @@ def validate_proxies():
logger.info(f'Our Backends Online: {len(our_valid_proxies)}, Smartproxy Backends Online: {len(smartproxy_valid_proxies)}, Smartproxy Broken Backends: {len(smartproxy_broken_proxies)}, Total Online: {len(our_valid_proxies) + len(smartproxy_valid_proxies)}')
redis.set('balancer_online', 1)
time.sleep(10)
time.sleep(60)

View File

@ -16,7 +16,7 @@ SMARTPROXY_PASS = 'password'
# Fix the 503 error on some SmartProxy hosts.
# TODO: remove when fixed.
SMARTPROXY_BV3HI_FIX = [
'https://files.catbox.moe/c8p1q6.png'
'https://files.catbox.moe/1hvrlj.png'
]
# Some domains just don't work through SmartProxy. Domains in this list are routed though