Skip to content

Commit

Permalink
Support tag with date.
Browse files Browse the repository at this point in the history
  • Loading branch information
winlinvip committed Nov 9, 2023
1 parent fa21ebe commit 00b0cdd
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ jobs:
- name: Covert output to env
run: |
echo "SRS_TAG=${{ needs.envs.outputs.SRS_TAG }}" >> $GITHUB_ENV
echo "SRS_TAG_DATE=$SRS_TAG$(date +%y-%m-%d)" >> $GITHUB_ENV
# Docker build
- name: Checkout repository
uses: actions/checkout@v3
Expand All @@ -47,6 +48,12 @@ jobs:
- name: Push to docker hub
run: |
docker push ossrs/srs:$SRS_TAG
- name: Copy to docker registry
uses: akhilerm/[email protected]
with:
src: ossrs/srs:${{ env.SRS_TAG }}
dst: |
ossrs/srs:${{ env.SRS_TAG_DATE }}
outputs:
SRS_DOCKER_PROD_DONE: ok

Expand All @@ -59,6 +66,7 @@ jobs:
- name: Covert output to env
run: |
echo "SRS_TAG=${{ needs.envs.outputs.SRS_TAG }}" >> $GITHUB_ENV
echo "SRS_TAG_DATE=$SRS_TAG$(date +%y-%m-%d)" >> $GITHUB_ENV
- name: Login aliyun hub
uses: docker/login-action@v2
with:
Expand All @@ -71,6 +79,7 @@ jobs:
src: ossrs/srs:${{ env.SRS_TAG }}
dst: |
registry.cn-hangzhou.aliyuncs.com/ossrs/srs:${{ env.SRS_TAG }}
registry.cn-hangzhou.aliyuncs.com/ossrs/srs:${{ env.SRS_TAG_DATE }}
outputs:
SRS_ALIYUN_PROD_DONE: ok

Expand Down

0 comments on commit 00b0cdd

Please sign in to comment.