Skip to content

Commit 5fcf84e

Browse files
author
kongfang
committed
更新workflow中的仓库
1 parent ddcca66 commit 5fcf84e

File tree

1 file changed

+32
-36
lines changed

1 file changed

+32
-36
lines changed

.github/workflows/publish.yml

Lines changed: 32 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -8,40 +8,36 @@ on:
88
jobs:
99
build-and-push:
1010
runs-on: ubuntu-latest
11-
11+
1212
steps:
13-
- name: Checkout code
14-
uses: actions/checkout@v3
15-
16-
- name: Get tag
17-
id: get_tag
18-
run: echo "TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
19-
20-
- name: Set up Docker Buildx
21-
uses: docker/setup-buildx-action@v2
22-
23-
- name: Integration tests
24-
run: "docker compose \
25-
-f docker-compose.yml -f docker-compose-integration.yml \
26-
up \
27-
--build \
28-
--abort-on-container-exit \
29-
--exit-code-from integration"
30-
31-
- name: Login to Docker Hub
32-
uses: docker/login-action@v2
33-
with:
34-
username: ${{ secrets.DOCKERHUB_USERNAME }}
35-
password: ${{ secrets.DOCKERHUB_TOKEN }}
36-
37-
- name: Build and push
38-
uses: docker/build-push-action@v4
39-
with:
40-
context: .
41-
platforms: linux/amd64,linux/arm64
42-
build-args: |
43-
KOMPANION_VERSION=${{ steps.get_tag.outputs.TAG }}
44-
push: true
45-
tags: |
46-
vanadium23/kompanion:latest
47-
vanadium23/kompanion:${{ steps.get_tag.outputs.TAG }}
13+
- name: Checkout code
14+
uses: actions/checkout@v3
15+
16+
- name: Get tag
17+
id: get_tag
18+
run: echo "TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
19+
20+
- name: Set up Docker Buildx
21+
uses: docker/setup-buildx-action@v2
22+
23+
- name: Integration tests
24+
run: "docker compose -f docker-compose.yml -f docker-compose-integration.yml up --build --abort-on-container-exit
25+
--exit-code-from integration"
26+
27+
- name: Login to Docker Hub
28+
uses: docker/login-action@v2
29+
with:
30+
username: ${{ secrets.DOCKERHUB_USERNAME }}
31+
password: ${{ secrets.DOCKERHUB_TOKEN }}
32+
33+
- name: Build and push
34+
uses: docker/build-push-action@v4
35+
with:
36+
context: .
37+
platforms: linux/amd64,linux/arm64
38+
build-args: |
39+
KOMPANION_VERSION=${{ steps.get_tag.outputs.TAG }}
40+
push: true
41+
tags: |
42+
xnowme/kompanion:latest
43+
xnowme/kompanion:${{ steps.get_tag.outputs.TAG }}

0 commit comments

Comments
 (0)