-
Notifications
You must be signed in to change notification settings - Fork 5
42 lines (42 loc) · 1.13 KB
/
tag.yaml
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
41
42
name: Bump Git/Docker Version
on:
push:
branches:
- main
jobs:
semver:
runs-on: ubuntu-latest
outputs:
tag: ${{ steps.tagging.outputs.new_tag }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: '0'
- name: Bump version and push tag
uses: anothrNick/[email protected]
id: tagging
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
WITH_V: true
RELEASE_BRANCHES: main
docker:
runs-on: ubuntu-latest
needs: semver
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ github.repository_owner }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v2
with:
push: true
tags: ${{ github.repository }}:${{ needs.semver.outputs.tag }}
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}