Skip to content

Commit 7074694

Browse files
authored
Merge pull request #369 from hardillb/master
Allow manual respin of existing tags
2 parents d3c0794 + c2e0d62 commit 7074694

File tree

1 file changed

+24
-1
lines changed

1 file changed

+24
-1
lines changed

.github/workflows/main.yml

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@ name: Docker Build
44

55
# Controls when the action will run.
66
on:
7+
workflow_dispatch:
8+
inputs:
9+
version:
10+
required: true
11+
type: string
12+
description: "Version"
713
release:
814
types: [published]
915

@@ -66,7 +72,24 @@ jobs:
6672
fi
6773
done <<< "${{ steps.meta.outputs.tags }}"
6874
69-
TRAVIS_TAG=$(echo $GITHUB_REF | awk -F '/' '{ print $3}')
75+
echo "Start Tags = $TAGS"
76+
echo "GITHUB_REF = $GITHUB_REF"
77+
78+
echo "version = ${{ github.event.inputs.version }}"
79+
80+
if [[ ! -z "${{ github.event.inputs.version }}" ]]; then
81+
TEMP=${{ github.event.inputs.version }}
82+
TEMP=${TEMP:1}
83+
TEMP2=$(echo $GITHUB_REF | awk -F '/' '{ print $3}')
84+
echo "$GITHUB_REF - $TEMP"
85+
TAGS=$(echo $TAGS | sed "s/$TEMP2/$TEMP/")
86+
TRAVIS_TAG=${{ github.event.inputs.version }}
87+
else
88+
TRAVIS_TAG=$(echo $GITHUB_REF | awk -F '/' '{ print $3}')
89+
fi
90+
91+
echo "TRAVIS_TAG = $TRAVIS_TAG"
92+
7093
if [[ "$TRAVIS_TAG" =~ ^v[0-9\.-]*$ ]]; then
7194
IMAGE=${{ env.DEFAULT_IMAGE }}
7295
PUSH="true"

0 commit comments

Comments
 (0)