Skip to content

ft(assets): diagram #40

ft(assets): diagram

ft(assets): diagram #40

name: Publish Docker image
on:
push:
branches: ['main']
jobs:
push_to_registry:
name: Push Docker image to Docker Hub
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v3
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
- name: Extract metadata (tags, labels) for Docker
id: metadata
uses: docker/metadata-action@v4
with:
images: siddhantprateek/qdapi
- name: Build and push Docker image
uses: mr-smithers-excellent/docker-build-push@v6
with:
image: siddhantprateek/qdapi
push: true
registry: docker.io
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
tags: latest
labels: ${{ steps.meta.outputs.labels }}