diff options
| author | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2021-10-25 14:53:54 +0200 |
|---|---|---|
| committer | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2021-10-25 14:53:54 +0200 |
| commit | aa9b32f8cd1467e9718959f400f6777e5d71737d (patch) | |
| tree | b88bbede15108c6855d7f94ded4c7054df186a72 /.github/workflows | |
| parent | eb0e0a3bc557c05a70eead388797ab850ea87366 (diff) | |
| parent | b7a71e5b4aa77b41ef41deec2ace42b67a5a13a7 (diff) | |
merge: Integrate v2.1 progress into public repository
This pull request integrates the changes planned for the v2.1 release of
OpenDC into the public Github repository in order to sync the progress
of both repositories.
Diffstat (limited to '.github/workflows')
| -rw-r--r-- | .github/workflows/build.yml | 44 | ||||
| -rw-r--r-- | .github/workflows/release.yml | 17 |
2 files changed, 43 insertions, 18 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index cbf2f80d..9bd42254 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -3,6 +3,8 @@ name: Build on: pull_request: branches: [master] + push: + branches: [master] jobs: build-simulator: @@ -11,7 +13,10 @@ jobs: strategy: matrix: os: [ubuntu-latest] - java: [8, 15] + java: [11, 16] + include: + - os: windows-latest + java: 16 steps: - name: Checkout repository uses: actions/checkout@v2 @@ -23,16 +28,25 @@ jobs: java-version: ${{ matrix.java }} - name: Grant execute permission for gradlew run: chmod +x gradlew - - uses: actions/cache@v1 + - uses: actions/cache@v2 with: - path: ~/.gradle/caches - key: ${{ runner.os }}-${{ matrix.java }}-gradle-${{ hashFiles('**/*.gradle*') }} + path: | + ~/.gradle/caches + ~/.gradle/wrapper + key: ${{ runner.os }}-${{ matrix.java }}-gradle-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }} restore-keys: | ${{ runner.os }}-${{ matrix.java }}-gradle- - name: Build with Gradle - run: ./gradlew assemble + run: ./gradlew classes - name: Check with Gradle run: ./gradlew check codeCoverageReport + - name: Cleanup Gradle Daemons + run: ./gradlew --stop + - name: Cleanup Gradle Cache + run: | + rm -f ~/.gradle/caches/modules-2/modules-2.lock + rm -f ~/.gradle/caches/modules-2/gc.properties + shell: bash - name: Publish report if: always() uses: mikepenz/action-junit-report@v2 @@ -61,7 +75,7 @@ jobs: strategy: matrix: os: [ubuntu-latest] - python: [3.8] + python: [3.9] defaults: run: working-directory: opendc-web/opendc-web-api @@ -78,19 +92,19 @@ jobs: - name: Lint with pylint run: ./check.sh - name: Test with pytest - run: pytest --cov=opendc/ --junitxml=.junit-report.xml + run: pytest --cov --cov-report=xml --junitxml=junit-report.xml - name: Publish report if: always() uses: mikepenz/action-junit-report@v2 with: check_name: test (Python ${{ matrix.python }}) - report_paths: '**/.junit-report.xml' + report_paths: '**/junit-report.xml' github_token: ${{ secrets.GITHUB_TOKEN }} - name: Upload code coverage uses: codecov/codecov-action@v1 with: token: ${{ secrets.CODECOV_TOKEN }} - files: opendc-web/opendc-web-api/.coverage + files: opendc-web/opendc-web-api/coverage.xml flags: api build-ui: name: Build UI (Node ${{ matrix.node }}) @@ -98,18 +112,20 @@ jobs: strategy: matrix: os: [ubuntu-latest] - node: [14.x] + node: [16] defaults: run: working-directory: opendc-web/opendc-web-ui steps: - uses: actions/checkout@v2 - name: Set up Node.js - uses: actions/setup-node@v1 + uses: actions/setup-node@v2 with: node-version: ${{ matrix.node }} - - run: npm install - - run: npm run build --if-present - - run: npm test + - run: yarn install --frozen-lockfile + - run: yarn build + env: + CI: true + - run: yarn next lint env: CI: true diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f76cdd09..c525eb97 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,7 +10,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - java: [ 15 ] + java: [ 16 ] steps: - name: Checkout repository uses: actions/checkout@v2 @@ -22,10 +22,12 @@ jobs: java-version: ${{ matrix.java }} - name: Grant execute permission for gradlew run: chmod +x gradlew - - uses: actions/cache@v1 + - uses: actions/cache@v2 with: - path: ~/.gradle/caches - key: ${{ runner.os }}-${{ matrix.java }}-gradle-${{ hashFiles('**/*.gradle*') }} + path:| + ~/.gradle/caches + ~/.gradle/wrapper + key: ${{ runner.os }}-${{ matrix.java }}-gradle-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }} restore-keys: | ${{ runner.os }}-${{ matrix.java }}-gradle- - name: Build with Gradle @@ -46,3 +48,10 @@ jobs: files: build/distributions/* env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Cleanup Gradle Daemons + run: ./gradlew --stop + - name: Cleanup Gradle Cache + run: | + rm -f ~/.gradle/caches/modules-2/modules-2.lock + rm -f ~/.gradle/caches/modules-2/gc.properties + shell: bash |
