Skip to content

Nightly build

Nightly build #171

Workflow file for this run

name: Nightly build
env:
ZINC_VERSION: "v0.1.5-ING-13"
on:
schedule:
# Run Monday and Wednesday at 04:00, so we don't use up our run hours too fast
- cron: '0 4 * * 1,3'
workflow_dispatch:
jobs:
all-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 8.0.232
uses: actions/setup-java@v2
with:
distribution: zulu
java-version: 8.0.232
java-package: jdk
# Build cache
- name: Cache Gradle Cache
uses: actions/cache@v3
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle.kts') }}-${{ hashFiles('**/gradle.properties') }}
# An ordered list of keys to use for restoring the cache if no cache hit occurred for key
restore-keys: |
${{ runner.os }}-gradle-
- name: Cache gradle wrapper
uses: actions/cache@v3
with:
path: ~/.gradle/wrapper
key: ${{ runner.os }}-gradle-wrapper-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }}
- name: Fetch Zinc ING Fork
uses: dsaltares/fetch-gh-release-asset@master
with:
repo: "mvdbos/zinc"
version: "tags/${{ env.ZINC_VERSION }}"
file: "zinc-linux.tar.gz"
token: ${{ secrets.GITHUB_TOKEN }}
env:
GITHUB_USERNAME: ${{ github.actor }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Install Zinc ING Fork and add to $PATH
run: |
tar xvzf zinc-linux.tar.gz
echo "$GITHUB_WORKSPACE/zinc-linux/" >> $GITHUB_PATH
- name: Build with Gradle
run: ./gradlew clean cleanTest check test testReport jacocoRootReport checkLicense spotBugsMain dependencyCheckAggregate --no-build-cache --rerun-tasks --no-daemon --no-parallel --stacktrace --info
env:
GITHUB_USERNAME: ${{ github.actor }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Sample ZKDapp - Build with Gradle
run: ./gradlew clean cleanTest build --no-build-cache --rerun-tasks --no-daemon --no-parallel --stacktrace --info
working-directory: sample-zkdapp
env:
GITHUB_USERNAME: ${{ github.actor }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Upload JUnit test report
if: always()
uses: actions/upload-artifact@v3
with:
name: Junit Test Report
path: build/reports/tests/test
- name: Upload JaCoCo report
if: always()
uses: actions/upload-artifact@v3
with:
name: JaCoCo Report
path: build/reports/jacoco/aggregate/html
- name: Upload OWASP report
if: always()
uses: actions/upload-artifact@v3
with:
name: OWASP Dependency Check Report
path: build/reports/dependency-check-report.html
- name: Upload detekt report
if: always()
uses: actions/upload-artifact@v3
with:
name: Detekt Report
path: build/reports/detekt