mirror of
https://github.com/keven1024/015.git
synced 2026-05-26 07:08:02 +00:00
chore(workflows): update image tagging strategy in publish.yaml to use semver and improve deployment conditions
This commit is contained in:
@@ -21,8 +21,8 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
images: fudaoyuanicu/015-app
|
images: fudaoyuanicu/015-app
|
||||||
tags: |
|
tags: |
|
||||||
type=pep440,pattern={{version}}
|
type=semver,pattern={{version}}
|
||||||
type=raw,value=latest,enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
|
type=raw,value=latest,enable=${{ !contains(github.ref_name, '-') }}
|
||||||
- name: Set build time
|
- name: Set build time
|
||||||
id: build-time
|
id: build-time
|
||||||
run: |
|
run: |
|
||||||
@@ -56,8 +56,8 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
images: fudaoyuanicu/015-worker
|
images: fudaoyuanicu/015-worker
|
||||||
tags: |
|
tags: |
|
||||||
type=pep440,pattern={{version}}
|
type=semver,pattern={{version}}
|
||||||
type=raw,value=latest,enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
|
type=raw,value=latest,enable=${{ !contains(github.ref_name, '-') }}
|
||||||
- name: Set build time
|
- name: Set build time
|
||||||
id: build-time
|
id: build-time
|
||||||
run: |
|
run: |
|
||||||
@@ -76,6 +76,7 @@ jobs:
|
|||||||
deploy:
|
deploy:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: [build-app, build-worker]
|
needs: [build-app, build-worker]
|
||||||
|
if: ${{ !contains(github.ref_name, '-') }}
|
||||||
steps:
|
steps:
|
||||||
- name: Send deployment webhook
|
- name: Send deployment webhook
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Reference in New Issue
Block a user