name: core-build on: push: branches: - '**' # matches every branch - '!coverity_scan' # excludes coverity_scan 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, without] # we can include specific combinations here include: - os: ubuntu-20.04 compiler: clang9 modules: without - os: ubuntu-18.04 compiler: clang # default in 18.04 is clang 6 modules: without - os: ubuntu-18.04 compiler: gcc8 modules: without - os: ubuntu-20.04 compiler: gcc # default in 20.04 is gcc 9 modules: without - os: ubuntu-20.04 compiler: gcc10 modules: without runs-on: ${{ matrix.os }} name: ${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.modules }}-modules env: COMPILER: ${{ matrix.compiler }} 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: /home/runner/.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: Run Core Build Action id: build-action uses: azerothcore/acore-core-build-action@main continue-on-error: true - name: Configure OS run: echo "${{ steps.build-action.outputs.configure-os }}" - name: Create conf/config.sh run: echo "${{ steps.build-action.outputs.config-sh }}" - name: Import DB run: echo "${{ steps.build-action.outputs.import-db }}" - name: Build run: echo "${{ steps.build-action.outputs.build }}" - name: Dry Run run: echo "${{ steps.build-action.outputs.dry-run }}" - name: Check Startup Errors run: echo "${{ steps.build-action.outputs.startup-errors }}" - name: Run Unit Tests run: echo "${{ steps.build-action.outputs.unit-tests }}" mac-build: strategy: fail-fast: false matrix: os: - macos-10.15 # - macos-11.0 runs-on: ${{ matrix.os }} name: ${{ matrix.os }} needs: [build] if: github.repository == 'azerothcore/azerothcore-wotlk' && success() steps: - uses: actions/checkout@v2 - name: Cache uses: actions/cache@v1.1.2 with: path: ~/.ccache key: ccache:${{ matrix.os }}:${{ github.ref }}:${{ github.sha }} restore-keys: | ccache:${{ matrix.os }}:${{ github.ref }} ccache:${{ matrix.os }} - name: Install latest bash run: brew install bash - name: Configure OS run: source ./acore.sh install-deps - name: Build run: source ./apps/ci/mac/ci-compile.sh - name: Run unit tests run: source ./apps/ci/ci-run-unit-tests.sh windows-build: strategy: fail-fast: false runs-on: windows-2019 name: windows-2019-MSVC16 if: github.repository == 'azerothcore/azerothcore-wotlk' steps: - uses: actions/checkout@v2 - name: Configure OS run: choco install --no-progress openssl - name: Build shell: bash run: | mkdir -p build && cd build cmake .. -DTOOLS=ON cmake --build . --config Release --parallel 4 - name: Copy dll files shell: bash run: | cp "/c/mysql-5.7.21-winx64/lib/libmysql.dll" "build/bin/Release/" cp "/c/Program Files/OpenSSL-Win64/bin/libcrypto-1_1-x64.dll" "build/bin/Release/" cp "/c/Program Files/OpenSSL-Win64/bin/libssl-1_1-x64.dll" "build/bin/Release/" - uses: actions/upload-artifact@v2 with: name: windows-2019-MSVC16-release path: build/bin/Release docker-build: strategy: fail-fast: true runs-on: ubuntu-20.04 if: github.repository == 'azerothcore/azerothcore-wotlk' steps: - uses: actions/checkout@v2 - name: Configure run: | docker --version docker-compose --version - name: Build run: | ./bin/acore-docker-build-no-scripts docker-worldserver: strategy: fail-fast: true runs-on: ubuntu-20.04 if: github.repository == 'azerothcore/azerothcore-wotlk' steps: - uses: actions/checkout@v2 - name: Configure run: | docker --version docker-compose --version - name: Build run: | docker build -t azerothcore/worldserver -f docker/worldserver/Dockerfile docker/worldserver docker-authserver: strategy: fail-fast: true runs-on: ubuntu-20.04 if: github.repository == 'azerothcore/azerothcore-wotlk' steps: - uses: actions/checkout@v2 - name: Configure run: | docker --version docker-compose --version - name: Build run: | docker build -t azerothcore/authserver -f docker/authserver/Dockerfile docker/authserver docker-database: strategy: fail-fast: true runs-on: ubuntu-20.04 if: github.repository == 'azerothcore/azerothcore-wotlk' steps: - uses: actions/checkout@v2 - name: Configure run: | docker --version docker-compose --version - name: Build run: | docker build -t azerothcore/database -f docker/database/Dockerfile .