Skip to content

chore: fix build

chore: fix build #68

Workflow file for this run

name: Release
on:
push:
branches:
- main
jobs:
build-server:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: docker/setup-buildx-action@v3
- name: Login to ghcr.io
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Setup JDK
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '21'
cache: 'sbt'
- name: Publish server docker image
run: sbt server/Docker/publish
build-frontend:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./ui/
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: docker/setup-buildx-action@v3
- name: Login to ghcr.io
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Setup JDK
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '21'
cache: 'sbt'
- name: Set up Node
uses: actions/setup-node@v4
with:
node-version: 18
cache: 'npm'
cache-dependency-path: './ui'
- name: Install dependencies
run: npm install
- name: Build
run: npm run build
- name: Publish frontend docker image
uses: docker/build-push-action@v5
with:
context: ./ui
file: "ui/Dockerfile.nginx"
tags: ghcr.io/${{ github.actor }}/controltower-fe:latest
load: true
cache-from: type=gha
cache-to: type=gha,mode=max
push: true