Skip to content

Add DAVE support

Add DAVE support #70

Workflow file for this run

# This workflow will build a Java project with Gradle
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
name: Gradle Build
on: [push]
permissions:
contents: read
packages: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 17
uses: actions/setup-java@v1
with:
java-version: 17
- name: Cache Gradle packages
uses: actions/cache@v4
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
restore-keys: ${{ runner.os }}-gradle
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build with Gradle
run: ./gradlew build
- name: Docker Login
uses: docker/login-action@v3
if: github.repository == 'freyacodes/ukulele'
with:
registry: ghcr.io
username: ${{github.repository_owner}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Get branch name
if: github.repository == 'freyacodes/ukulele'
run: echo "BRANCH_NAME=${GITHUB_REF#refs/heads/}" >> $GITHUB_ENV
- name: Docker build and push
uses: docker/build-push-action@v6
if: github.repository == 'freyacodes/ukulele'
with:
tags: ghcr.io/freyacodes/ukulele:${{env.BRANCH_NAME}}
load: true
context: .
- run: docker push ghcr.io/freyacodes/ukulele:${{env.BRANCH_NAME}}
if: github.repository == 'freyacodes/ukulele'