1027
All checks were successful
Clone Repository with Trojan-Go Proxy / clone_with_proxy (push) Successful in 1m13s
All checks were successful
Clone Repository with Trojan-Go Proxy / clone_with_proxy (push) Successful in 1m13s
This commit is contained in:
parent
1942ba55ed
commit
21be234612
28
.github/workflows/BBB.yml
vendored
28
.github/workflows/BBB.yml
vendored
@ -63,3 +63,31 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
echo "Checking ALL_PROXY: $ALL_PROXY"
|
echo "Checking ALL_PROXY: $ALL_PROXY"
|
||||||
git clone --depth 1 $REPO_URL -b $REPO_BRANCH
|
git clone --depth 1 $REPO_URL -b $REPO_BRANCH
|
||||||
|
|
||||||
|
# 1. 不使用代理的步骤
|
||||||
|
- name: 🌐 Step without Proxy
|
||||||
|
run: |
|
||||||
|
echo "Checking if ALL_PROXY is set (no proxy expected):"
|
||||||
|
if [ -z "$ALL_PROXY" ]; then
|
||||||
|
echo "No ALL_PROXY set. Not using proxy."
|
||||||
|
else
|
||||||
|
echo "ALL_PROXY is set to $ALL_PROXY. Proxy in use."
|
||||||
|
fi
|
||||||
|
echo "Attempting to access example.com without proxy..."
|
||||||
|
curl -s --max-time 10 https://example.com || echo "Request failed, likely due to no proxy."
|
||||||
|
|
||||||
|
# 2. 使用代理的步骤
|
||||||
|
- name: 🌐 Step with Proxy
|
||||||
|
env:
|
||||||
|
ALL_PROXY: "socks5://127.0.0.1:1080"
|
||||||
|
http_proxy: "socks5://127.0.0.1:1080"
|
||||||
|
https_proxy: "socks5://127.0.0.1:1080"
|
||||||
|
run: |
|
||||||
|
echo "Checking if ALL_PROXY is set (proxy expected):"
|
||||||
|
if [ -z "$ALL_PROXY" ]; then
|
||||||
|
echo "No ALL_PROXY set. Not using proxy."
|
||||||
|
else
|
||||||
|
echo "ALL_PROXY is set to $ALL_PROXY. Proxy in use."
|
||||||
|
fi
|
||||||
|
echo "Attempting to access example.com with proxy..."
|
||||||
|
curl -s --max-time 10 https://example.com || echo "Request failed, even with proxy."
|
Loading…
Reference in New Issue
Block a user