update action
This commit is contained in:
10
.github/workflows/ci.yaml
vendored
10
.github/workflows/ci.yaml
vendored
@@ -6,7 +6,7 @@ on:
|
|||||||
- main
|
- main
|
||||||
- dev
|
- dev
|
||||||
tags:
|
tags:
|
||||||
- '*'
|
- 'v*'
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [ "main","dev" ]
|
branches: [ "main","dev" ]
|
||||||
|
|
||||||
@@ -25,11 +25,14 @@ jobs:
|
|||||||
submodules: 'true'
|
submodules: 'true'
|
||||||
- name: Get current date
|
- name: Get current date
|
||||||
id: date
|
id: date
|
||||||
run: echo "::set-output name=today::$(date +'%Y%m%d')"
|
run: echo "::set-output name=today::$(date +'%Y%m%d')"
|
||||||
- name: Set up QEMU
|
- name: Set up QEMU
|
||||||
uses: docker/setup-qemu-action@v2
|
uses: docker/setup-qemu-action@v2
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
|
id: buildx
|
||||||
uses: docker/setup-buildx-action@v2
|
uses: docker/setup-buildx-action@v2
|
||||||
|
- name: Available platforms
|
||||||
|
run: echo ${{ steps.buildx.outputs.platforms }}
|
||||||
- name: Login to DockerHub
|
- name: Login to DockerHub
|
||||||
uses: docker/login-action@v2
|
uses: docker/login-action@v2
|
||||||
with:
|
with:
|
||||||
@@ -47,9 +50,8 @@ jobs:
|
|||||||
platforms: linux/amd64,linux/arm64
|
platforms: linux/amd64,linux/arm64
|
||||||
#指定用户/仓库名
|
#指定用户/仓库名
|
||||||
tags: |
|
tags: |
|
||||||
${{ github.repository }}:${{ github.ref_slug }}
|
|
||||||
${{ github.repository }}:latest
|
|
||||||
${{ github.repository }}:${{ steps.date.outputs.today }}
|
${{ github.repository }}:${{ steps.date.outputs.today }}
|
||||||
|
${{ github.repository }}:${{ contains(github.ref,'main') && 'latest' || github.ref_name }}
|
||||||
- name: Docker Hub Description
|
- name: Docker Hub Description
|
||||||
#这里是通过md文件自动生成dockerhub描述的模块,也可以不需要
|
#这里是通过md文件自动生成dockerhub描述的模块,也可以不需要
|
||||||
uses: peter-evans/dockerhub-description@v3
|
uses: peter-evans/dockerhub-description@v3
|
||||||
|
|||||||
Reference in New Issue
Block a user