Skip to content

Commit

Permalink
workflows: add release image workflows
Browse files Browse the repository at this point in the history
Signed-off-by: Xieql <[email protected]>
  • Loading branch information
Xieql authored and kurator-bot committed Oct 30, 2023
1 parent 9fb9f68 commit 5079501
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/release-image.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Build and Push Images

on:
push:
tags:
- 'v*.*.*'

jobs:
build-push:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Setup Go
uses: actions/setup-go@v4
with:
go-version: 1.20.x

- name: Compile
run: make build

- name: Build Docker Image
# Use version tag
run: VERSION=${{ github.ref_name }} make docker

- name: Login to ghcr.io
# This is where you will update the PAT to GITHUB_TOKEN
run: echo "${{ secrets.GH_PAT }}" | docker login ghcr.io -u $ --password-stdin

- name: Push Docker Image
run: VERSION=${{ github.ref_name }} make docker-push

0 comments on commit 5079501

Please sign in to comment.