ci: 调整workflow
All checks were successful
deploy to server / build-and-deploy (push) Successful in 7m38s

- 添加为构建工作流添加检测代理是否启用的job
This commit is contained in:
2025-09-27 10:30:27 +08:00
parent 7fae419708
commit 06c79dc520

View File

@ -6,6 +6,16 @@ jobs:
build-and-deploy:
runs-on: node22-build
steps:
- name: Check Proxy
run: |
echo "HTTP_PROXY = $HTTP_PROXY"
echo "HTTPS_PROXY = $HTTPS_PROXY"
# 测试网络是否能透过代理访问一个外部 URL比如 google.com
# 也可以换成你常用的 npm registry / GitHub
curl -I https://www.google.com --max-time 10 || echo "curl to google failed"
# 测试拉取 npm 包或 ping github.com
curl -I https://registry.npmjs.org --max-time 10 || echo "curl to registry.npmjs.org failed"
ping -c 3 github.com || echo "ping github.com failed"
- name: Checkout
uses: actions/checkout@v5
- name: Setup pnpm