@@ -24,8 +24,17 @@ jobs:
|
|||||||
image: docker:24
|
image: docker:24
|
||||||
options: --network infra-infra-net
|
options: --network infra-infra-net
|
||||||
steps:
|
steps:
|
||||||
- name: 安装 git / curl(alpine)
|
# dl-cdn 在 CI 容器内被出口防火墙拒(apk 报 Permission denied,索引拉不下来即 curl no such package),
|
||||||
run: apk add --no-cache git curl
|
# 切国内镜像源安装;aliyun 不通再退 ustc,最后兜底官方源
|
||||||
|
- name: 安装 git / curl(alpine,国内镜像源)
|
||||||
|
run: |
|
||||||
|
set -e
|
||||||
|
for m in mirrors.aliyun.com mirrors.ustc.edu.cn dl-cdn.alpinelinux.org; do
|
||||||
|
sed -i "s#https://[^/]*#https://$m#" /etc/apk/repositories
|
||||||
|
echo ">> trying mirror: $m"
|
||||||
|
if apk add --no-cache git curl; then break; fi
|
||||||
|
done
|
||||||
|
git --version && curl --version | head -1
|
||||||
|
|
||||||
# 内网 Gitea 无法访问 GitHub 拉 actions/checkout,手动 clone 本仓库
|
# 内网 Gitea 无法访问 GitHub 拉 actions/checkout,手动 clone 本仓库
|
||||||
- name: 拉取源码(内网无 GitHub,手动 clone 本仓库)
|
- name: 拉取源码(内网无 GitHub,手动 clone 本仓库)
|
||||||
|
|||||||
Reference in New Issue
Block a user