Skip to content

[cicd][cluster] remove git #549

[cicd][cluster] remove git

[cicd][cluster] remove git #549

Workflow file for this run

name: docker_image_ci
on:
push:
branches: [ "main", "develop" ]
pull_request:
types: [closed]
branches: [ "main", "develop" ]
jobs:
release:
if: ( github.event.pull_request.merged == true && github.repository == 'dongshanyi/dingo-command' ) || github.event_name == 'push'
runs-on: ubuntu-latest
permissions:
packages: write
contents: read
steps:
- uses: actions/checkout@v4
# setup Docker buld action
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v3
- name: Login to Github Packages
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build image and push to Docker Hub and GitHub Container Registry
uses: docker/build-push-action@v6
with:
# relative path to the place where source code with Dockerfile is located
context: .
file: ./docker/Dockerfile
# Note: tags has to be all lower-case
tags: dingodatabase/dingo-command:latest
# build on feature branches, push only on develop branch
push: ${{ github.ref == 'refs/heads/develop' || github.ref == 'refs/heads/main' }}
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}