Skip to content

Devops/build automation #2290

Devops/build automation

Devops/build automation #2290

Workflow file for this run

---
name: Build And Test CWMS Data API
on:
push:
branches:
- develop
pull_request:
branches:
- develop
jobs:
build:
name: build and test
runs-on: ubuntu-latest
outputs:
thewar: ${{steps.thebuild.outputs.WARFILE}}
steps:
- name: checkout code
uses: actions/[email protected]
- name: setup java
uses: actions/[email protected]
with:
distribution: 'temurin'
java-version: '8'
cache: 'gradle'
- name: build and test
id: thebuild
run: ./gradlew build --info --init-script init.gradle
- name: integration tests
run: ./gradlew integrationtest --info --init-script init.gradle
- name: Upload WAR
uses: actions/[email protected]
with:
name: warfile
path: cwms-data-api/build/libs/${{steps.thebuild.outputs.WARFILE}}
retention-days: 1
if-no-files-found: error
- name: Build docker image
run: docker build -t cda:build-latest .