From d0c6e137fa27845981693c1e794a364c7063443f Mon Sep 17 00:00:00 2001 From: Patrick Lewis Date: Thu, 17 Jun 2021 14:54:39 -0700 Subject: [PATCH] feat(CI): move modules build into separate workflow (#6277) --- .github/README.md | 1 + .github/workflows/core_build.yml | 2 +- .github/workflows/core_modules_build.yml | 52 ++++++++++++++++++++++++ 3 files changed, 54 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/core_modules_build.yml diff --git a/.github/README.md b/.github/README.md index 29ebb6ec6..fbe346e75 100644 --- a/.github/README.md +++ b/.github/README.md @@ -2,6 +2,7 @@ [![CodeFactor](https://www.codefactor.io/repository/github/azerothcore/azerothcore-wotlk/badge)](https://www.codefactor.io/repository/github/azerothcore/azerothcore-wotlk) [![core-build](https://github.com/azerothcore/azerothcore-wotlk/workflows/core-build/badge.svg?branch=master&event=push)](https://github.com/azerothcore/azerothcore-wotlk/actions?query=workflow%3Acore-build+branch%3Amaster+event%3Apush) +[![core-modules-build](https://github.com/azerothcore/azerothcore-wotlk/workflows/core-modules-build/badge.svg?branch=master&event=push)](https://github.com/azerothcore/azerothcore-wotlk/actions?query=workflow%3Acore-modules-build+branch%3Amaster+event%3Apush) [![windows-build](https://github.com/azerothcore/azerothcore-wotlk/workflows/windows-build/badge.svg?branch=master&event=push)](https://github.com/azerothcore/azerothcore-wotlk/actions?query=workflow%3Awindows-build+branch%3Amaster+event%3Apush) [![macos-build](https://github.com/azerothcore/azerothcore-wotlk/workflows/macos-build/badge.svg?branch=master&event=push)](https://github.com/azerothcore/azerothcore-wotlk/actions?query=workflow%3Amacos-build+branch%3Amaster+event%3Apush) [![docker-build](https://github.com/azerothcore/azerothcore-wotlk/workflows/docker-build/badge.svg?branch=master&event=push)](https://github.com/azerothcore/azerothcore-wotlk/actions?query=workflow%3Adocker-build+branch%3Amaster+event%3Apush) diff --git a/.github/workflows/core_build.yml b/.github/workflows/core_build.yml index b378436a6..0a8350419 100644 --- a/.github/workflows/core_build.yml +++ b/.github/workflows/core_build.yml @@ -17,7 +17,7 @@ jobs: # the result of the matrix will be the combination of all attributes, so we get os*compiler*modules builds os: [ubuntu-20.04] compiler: [clang] - modules: [with, without] + modules: [without] extra_logs: [false] # we can include specific combinations here include: diff --git a/.github/workflows/core_modules_build.yml b/.github/workflows/core_modules_build.yml new file mode 100644 index 000000000..eec93f41a --- /dev/null +++ b/.github/workflows/core_modules_build.yml @@ -0,0 +1,52 @@ +name: core-modules-build +on: + push: + branches: + - 'master' + pull_request: + +jobs: + build: + strategy: + fail-fast: false + matrix: + # the result of the matrix will be the combination of all attributes, so we get os*compiler*modules builds + os: [ubuntu-20.04] + compiler: [clang] + modules: [with] + extra_logs: [false] + runs-on: ${{ matrix.os }} + name: ${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.modules }}-modules-extra_logs-${{ matrix.extra_logs }} + env: + COMPILER: ${{ matrix.compiler }} + EXTRA_LOGS: ${{ matrix.extra_logs }} + if: github.repository == 'azerothcore/azerothcore-wotlk' + steps: + - uses: actions/checkout@v2 + - name: Checkout modules + run: ./apps/ci/ci-install-modules.sh + if: matrix.modules == 'with' + - name: Cache + uses: actions/cache@v2 + with: + path: var/ccache + key: ccache:${{ matrix.os }}:${{ matrix.compiler }}:${{ matrix.modules }}-modules:${{ github.ref }}:${{ github.sha }} + restore-keys: | + ccache:${{ matrix.os }}:${{ matrix.compiler }}:${{ matrix.modules }}-modules:${{ github.ref }} + ccache:${{ matrix.os }}:${{ matrix.compiler }}:${{ matrix.modules }}-modules + - name: Configure OS + run: source ./acore.sh install-deps + env: + CONTINUOUS_INTEGRATION: true + - name: Create conf/config.sh + run: source ./apps/ci/ci-conf.sh + - name: Import db + run: source ./apps/ci/ci-import-db.sh + - name: Build + run: source ./apps/ci/ci-compile.sh + - name: Dry run + run: source ./apps/ci/ci-worldserver-dry-run.sh + - name: Check startup errors + run: source ./apps/ci/ci-error-check.sh + - name: Run unit tests + run: source ./apps/ci/ci-run-unit-tests.sh