ci(workflow): 更新Gitea工作流使用内部actions

使用内部认证的actions替换公开actions以增强安全性
This commit is contained in:
shanshanzhong 2025-08-05 08:22:04 -07:00
parent b6cbcb3040
commit bce4c4e56e

View File

@ -29,9 +29,12 @@ jobs:
go: ["1.24.3"] go: ["1.24.3"]
steps: steps:
- name: Checkout
uses: https://${{ env.GIT_USERNAME }}:${{ env.GIT_PASSWORD }}@${{ vars.DOMAIN_OF_GITEA}}/actions/checkout@main
# 将.env环境变量配置文件拷贝致gitea runner容器 # 将.env环境变量配置文件拷贝致gitea runner容器
- name: copy env file to runner container - name: copy env file to runner container
uses: appleboy/ssh-action@v1 uses: https://${{ env.GIT_USERNAME }}:${{ env.GIT_PASSWORD }}@${{ vars.DOMAIN_OF_GITEA}}/actions/ssh-action@main
with: with:
host: ${{ env.SSH_HOST }} host: ${{ env.SSH_HOST }}
username: ${{ env.SSH_USER }} username: ${{ env.SSH_USER }}
@ -52,7 +55,7 @@ jobs:
fi fi
- name: Setup Go environment with cache - name: Setup Go environment with cache
uses: actions/setup-go@v3 uses: https://${{ env.GIT_USERNAME }}:${{ env.GIT_PASSWORD }}@${{ vars.DOMAIN_OF_GITEA}}/actions/setup-go@main
with: with:
go-version: ${{ matrix.go }} go-version: ${{ matrix.go }}
cache: true cache: true