Skip to content

Update README.md

Update README.md #6

Workflow file for this run

name: Build and Push Docker Image
on:
push:
branches:
- main
jobs:
tests:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Setup-java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
- name: Run tests with maven
run: mvn clean test
build:
runs-on: ubuntu-latest
needs: tests
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Setup-java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
- name: Login to Docker Hub
run: docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD
- name: Build Docker Image
run: docker build -t $DOCKER_USERNAME/balancea:latest .
- name: Push Docker Image
run: docker push $DOCKER_USERNAME/balancea:latest