-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (40 loc) · 1.3 KB
/
auto_release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
on:
schedule:
- cron: '0 * * * *'
env:
DOCKER_USERNAME: percygrunwald
IMAGE_NAME: percygrunwald/docker-asdf-terraform-ci-base
GIT_AUTHOR_EMAIL: [email protected]
GIT_AUTHOR_NAME: Percy Grunwald
jobs:
auto_release:
runs-on: ubuntu-latest
steps:
- id: checkout
uses: actions/checkout@v2
- id: ci-script
run: |
# -c = git commit, -p = docker push, -t = git tag,
# -u = update dockerfile
script/ci.sh -cptu
env:
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
- id: print-release-tag
run: |
printf "${RELEASE_TAG}\n"
env:
RELEASE_TAG: ${{ steps.ci-script.outputs.release-tag }}
if: steps.ci-script.outputs.release-tag != ''
- id: git-push
run: |
printf "Running git push...\n" >&2
git push
printf "Running git push tags...\n" >&2
git push --tags
if: github.actor != 'nektos/act' && steps.ci-script.outputs.release-tag != ''
- id: git-release
uses: softprops/action-gh-release@v1
with:
name: ${{ steps.ci-script.outputs.release-tag }}
tag_name: ${{ steps.ci-script.outputs.release-tag }}
if: github.actor != 'nektos/act' && steps.ci-script.outputs.release-tag != ''