ci(workflows): 优化docker.yml配置以支持docker服务
- 在docker.yml工作流中添加docker-in-docker服务支持 - 配置服务端口2376并设置特权模式 - 添加环境变量DOCKER_HOST和DOCKER_TLS_VERIFY以正确连接docker服务 - 修正密码环境变量名称由GITEATOKEN改为GITEA_TOKEN保证一致性
This commit is contained in:
parent
b2478fb25b
commit
c12e3f22f1
@ -59,6 +59,15 @@ jobs:
|
||||
needs: build
|
||||
runs-on: ubuntu-latest
|
||||
if: gitea.event_name == 'push'
|
||||
services:
|
||||
docker:
|
||||
image: docker:dind
|
||||
ports:
|
||||
- 2376:2376
|
||||
options: --privileged
|
||||
env:
|
||||
DOCKER_HOST: tcp://localhost:2376
|
||||
DOCKER_TLS_VERIFY: ""
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
@ -90,7 +99,7 @@ jobs:
|
||||
with:
|
||||
registry: ${{ env.REGISTRY }}
|
||||
username: ${{ gitea.actor }}
|
||||
password: ${{ secrets.GITEATOKEN }}
|
||||
password: ${{ secrets.GITEA_TOKEN }}
|
||||
|
||||
- name: Extract metadata
|
||||
id: meta
|
||||
|
||||
Loading…
Reference in New Issue
Block a user