Skip to content

Publish To Docker Hub #57

Publish To Docker Hub

Publish To Docker Hub #57

Workflow file for this run

# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
name: Publish To Docker Hub
on:
workflow_dispatch:
push:
branches: [ master ]
jobs:
publish-docker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK
uses: actions/setup-java@v3
with:
java-version: '21'
distribution: 'liberica'
cache: maven
- name: Publish
run: mvn --batch-mode --activate-profiles docker --define no-zip spring-boot:build-image
env:
DOCKER_ID: ${{ secrets.DOCKER_ID }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}