Skip to content

Commit

Permalink
Created deploy.yml for Docker CD pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
praneeth622 committed Jul 15, 2024
1 parent 749dcd3 commit 18efafd
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name : Build and Deploy to Docker Hub

on : [push]

jobs:
build:
name : Deploy to Docker
runs-on : ubuntu-latest

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

- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '20'

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

- name : Build and Push Docker image
uses : docker/build-push-action@v2
with :
content : .
file: ./Dockerfile
push: true
tags: praneeth0331/dropit:latest

- name : Verify Pushed Image
run : docker pull praneeth0331/dropit:latest

0 comments on commit 18efafd

Please sign in to comment.