Skip to content

Commit

Permalink
build: Add workflow file to build and push docker image to docker hub
Browse files Browse the repository at this point in the history
  • Loading branch information
getwithashish committed Aug 9, 2024
1 parent 3e7533a commit a0dd9b9
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/build-push-docker-image.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Build and Push Docker image

on:
push:
branches:
- "docker-image"

jobs:
prepare-dataset:
runs-on: ubuntu-latest
environment: docker-container-registry

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Build and Push Docker Image
uses: docker/build-push-action@v5
with:
context: .
push: true
tags: getwithashish/expchatbot:latest

- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}

0 comments on commit a0dd9b9

Please sign in to comment.