Skip to content

Commit

Permalink
added workflow to test
Browse files Browse the repository at this point in the history
  • Loading branch information
HarshP4585 committed Feb 8, 2025
1 parent 972d1ed commit f6f8286
Showing 1 changed file with 56 additions and 0 deletions.
56 changes: 56 additions & 0 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Build and Push Docker Images

on:
push:
branches:
# - master
- test-branch-github-actions

jobs:
build-and-push:
runs-on: ubuntu-latest

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

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

- name: Debug Secret Access
run: |
if [ -z "${{ secrets.DOCKER_HUB_USERNAME }}" ]; then
echo "❌ DOCKER_HUB_USERNAME is NOT set!"
exit 1
else
echo "✅ DOCKER_HUB_USERNAME is set!"
fi
if [ -z "${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}" ]; then
echo "❌ DOCKER_HUB_ACCESS_TOKEN is NOT set!"
exit 1
else
echo "✅ DOCKER_HUB_ACCESS_TOKEN is set!"
fi
- name: Log in to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}

- name: Build and push Clients image
uses: docker/build-push-action@v4
with:
context: ./Clients
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ secrets.DOCKER_HUB_USERNAME }}/verifywise-frontend:testing

- name: Build and push Servers image
uses: docker/build-push-action@v4
with:
context: ./Servers
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ secrets.DOCKER_HUB_USERNAME }}/verifywise-backend:testing

0 comments on commit f6f8286

Please sign in to comment.