-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (36 loc) · 1.22 KB
/
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
41
42
43
name: Build and Push Docker Image on Release
on:
release:
types: [published]
env:
RELEASE_VERSION: ${{ github.event.release.tag_name }}
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
IMAGE_NAME: frontman
jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ env.DOCKER_USERNAME }}
password: ${{ env.DOCKER_PASSWORD }}
- name: Build Docker Image
run: |
docker build -t $IMAGE_NAME .
docker tag $IMAGE_NAME $DOCKER_USERNAME/$IMAGE_NAME:${{ env.RELEASE_VERSION }}
docker tag $IMAGE_NAME $DOCKER_USERNAME/$IMAGE_NAME:latest
- name: Push Docker Image
run: |
docker push $DOCKER_USERNAME/$IMAGE_NAME:${{ env.RELEASE_VERSION }}
docker push $DOCKER_USERNAME/$IMAGE_NAME:latest
build-chart:
needs: build-and-push
uses: frontman-labs/frontman-helm-chart/.github/workflows/build-chart.yml@main
with:
image: "hyperioxx/frontman:${{ github.event.release.tag_name }}"
version: "${{ github.event.release.tag_name }}"
secrets: inherit