mirror of
https://github.com/mveril/qp-demo
synced 2024-10-31 19:23:51 +01:00
Compare commits
6 Commits
456545ecc1
...
fed70ff484
Author | SHA1 | Date | |
---|---|---|---|
fed70ff484 | |||
c499dfca52 | |||
c70ff10919 | |||
5a403665c3 | |||
562ac3226a | |||
fbaa052489 |
4
.github/workflows/build.yml
vendored
4
.github/workflows/build.yml
vendored
@ -10,9 +10,6 @@ on:
|
||||
- master
|
||||
- release_*
|
||||
|
||||
# Allows you to run this workflow manually from the Actions tab
|
||||
workflow_dispatch:
|
||||
|
||||
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||
jobs:
|
||||
# This workflow contains a single job called "build"
|
||||
@ -36,7 +33,6 @@ jobs:
|
||||
context: ./
|
||||
file: ./Dockerfile
|
||||
push: false
|
||||
tags: ${{ secrets.DOCKER_HUB_USERNAME }}/qp_demo:${GITHUB_REF#refs/heads/}.${GITHUB_SHA::8}
|
||||
|
||||
- name: Image digest
|
||||
run: echo ${{ steps.docker_build.outputs.digest }}
|
11
.github/workflows/deploy.yml
vendored
11
.github/workflows/deploy.yml
vendored
@ -25,16 +25,21 @@ jobs:
|
||||
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Extract branch name
|
||||
shell: bash
|
||||
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})"
|
||||
id: extract_branch
|
||||
|
||||
- name: Get Docker tag from branch name
|
||||
id: extract_docker_tag
|
||||
shell: bash
|
||||
run: |
|
||||
if [ "${GITHUB_REF#refs/heads/}" == "master" ]; then
|
||||
if [ "${{ steps.extract_branch.outputs.branch }}" == "master" ]; then
|
||||
echo "##[set-output name=tag;]$(echo 'latest')"
|
||||
elif [[ "${GITHUB_REF#refs/heads/}" == release_* ]]; then
|
||||
elif [[ "${{ steps.extract_branch.outputs.branch }}" == release_* ]]; then
|
||||
echo "##[set-output name=tag;]$(echo '${GITHUB_REF#refs/heads/}' | cut -d '_' -f2-)"
|
||||
else
|
||||
echo "##[set-output name=tag;]$(echo 'ghtest')"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
- name: Login to Docker Hub
|
||||
|
Loading…
Reference in New Issue
Block a user