Skip to content

Merge pull request #149 from wanjunlei/release-0.8 #34

Merge pull request #149 from wanjunlei/release-0.8

Merge pull request #149 from wanjunlei/release-0.8 #34

name: Building kube-events-ruler image
on:
push:
branches:
- 'master'
tags:
- 'v*'
paths:
- ".github/workflows/build-ruler-image.yaml"
- "cmd/ruler/**"
- "hack/**"
- "pkg/**"
- "Makefile"
env:
REPO_RULER: 'kubesphere'
jobs:
ruler-build:
runs-on: ubuntu-latest
timeout-minutes: 30
name: Build Image for kube-events-ruler
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install Go
uses: actions/setup-go@v5
with:
go-version-file: 'go.mod'
- uses: actions/cache@v4
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.REGISTRY_USER }}
password: ${{ secrets.REGISTRY_PASSWORD }}
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v3
- name: Build and Push Image for kube-events-ruler
run: |
make cross-build-ruler -e REPO_RULER=${{ env.REPO_RULER }}/kube-events-ruler