v0.2.1 #4
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
workflow_dispatch: | |
inputs: | |
image_version: | |
description: 'image version for image build' | |
required: false | |
type: string | |
release: | |
types: | |
- created | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Check version | |
run: | | |
if [ ${{ inputs.image_version }} ]; then | |
echo "IMAGE_TAG=${{ inputs.image_version }}" >> $GITHUB_ENV | |
else | |
TAG=$(git describe --tags --match 'v*' | grep -oE 'v[0-9]+\.[0-9][0-9]*(\.[0-9]+)?') | |
echo "IMAGE_TAG=$TAG" >> $GITHUB_ENV | |
fi | |
- name: Login Docker Hub | |
run: docker login --username chnliyong --password ${PASSWORD} | |
env: | |
PASSWORD: ${{ secrets.DOCKERHUB_FUSE_ACCESS_TOKEN }} | |
- name: Build and push Docker image | |
run: make docker-buildx IMG=juicedata/juicefs-cache-group-operator:${{ env.IMAGE_TAG }} |