🛳️Docker image publishing automation workflow added - Adithya S K
Some checks failed
Docker Image CI / build-and-push (push) Has been cancelled

This commit is contained in:
adithya-s-k 2024-09-23 07:48:00 +00:00
parent ead63a84f5
commit e1cbb9c2b8

35
.github/workflows/docker-image.yml vendored Normal file
View File

@ -0,0 +1,35 @@
name: Docker Image CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile
push: true
tags: |
cognitivelab/omniparse:latest
cognitivelab/omniparse:${{ github.sha }}
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}