Add maxlaw PC spider and shared proxy limiter
This commit is contained in:
+16
-5
@@ -5,9 +5,20 @@ set -euo pipefail
|
||||
cd "$(dirname "$0")"
|
||||
|
||||
echo "使用 request/proxy_settings.json 读取代理配置"
|
||||
export PROXY_MAX_REQUESTS_PER_SECOND="${PROXY_MAX_REQUESTS_PER_SECOND:-5}"
|
||||
|
||||
nohup python ../common_sites/dls.py > dls.log 2>&1 & # 大律师
|
||||
nohup python ../common_sites/findlaw.py > findlaw.log 2>&1 & # 找法网
|
||||
nohup python ../common_sites/lawtime.py > lawtime.log 2>&1 & # 法律快车
|
||||
nohup python ../common_sites/six4365.py > six4365.log 2>&1 & # 律图
|
||||
nohup python ../common_sites/hualv.py > hualv.log 2>&1 & # 华律
|
||||
start_job() {
|
||||
local script="$1"
|
||||
local log_file="$2"
|
||||
local label="$3"
|
||||
nohup python "../common_sites/${script}" > "${log_file}" 2>&1 &
|
||||
echo "启动 ${label}: ${script} -> ${log_file}"
|
||||
sleep 1
|
||||
}
|
||||
|
||||
start_job "dls.py" "dls.log" "大律师"
|
||||
start_job "dls_pc.py" "dls_pc.log" "大律师PC站"
|
||||
start_job "findlaw.py" "findlaw.log" "找法网"
|
||||
start_job "lawtime.py" "lawtime.log" "法律快车"
|
||||
start_job "six4365.py" "six4365.log" "律图"
|
||||
start_job "hualv.py" "hualv.log" "华律"
|
||||
|
||||
Reference in New Issue
Block a user