Nightly Build #275
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Nightly Build | |
| on: | |
| push: | |
| branches: [ "main" ] | |
| pull_request: | |
| branches: [ "main" ] | |
| schedule: | |
| # Run every day at 12:00 AM (nightly builds) | |
| - cron: '0 12 * * *' | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| jobs: | |
| build-native: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| # Build native on both ubuntu 22.04 and 24.04 | |
| - os: ubuntu-22.04 | |
| - os: ubuntu-24.04 | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| # Checkout code | |
| - uses: actions/checkout@v3 | |
| # Perform Phoenix 6 installation process | |
| - name: Add Phoenix 6 to local apt | |
| run: | | |
| sudo curl -s --compressed -o /usr/share/keyrings/ctr-pubkey.gpg "https://deb.ctr-electronics.com/ctr-pubkey.gpg" | |
| sudo curl -s --compressed -o /etc/apt/sources.list.d/ctr2026.list "https://deb.ctr-electronics.com/ctr2026.list" | |
| # Update apt and install phoenix6 | |
| - name: Install Phoenix 6 | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install phoenix6 cmake build-essential libsdl2-dev -y | |
| # Build using CMake | |
| - name: Build Example | |
| run: | | |
| mkdir build | |
| cd build | |
| cmake .. | |
| make | |
| - name: Run Example | |
| run: | | |
| cd build | |
| timeout 10s ./Phoenix6-Example || ( [[ $? -eq 124 ]] && echo "Program started successfully" ) | |
| build-arm: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| # 64-bit arm on bookworm | |
| - arch: aarch64 | |
| distro: bookworm | |
| # 64-bit arm on trixie | |
| - arch: none | |
| distro: none | |
| base_image: --platform=linux/arm64 arm64v8/debian:trixie | |
| # 64-bit arm on ubuntu 22.04 | |
| - arch: aarch64 | |
| distro: ubuntu22.04 | |
| # 64-bit arm on ubuntu 24.04 | |
| - arch: aarch64 | |
| distro: ubuntu24.04 | |
| runs-on: ubuntu-latest | |
| steps: | |
| # Checkout code | |
| - uses: actions/checkout@v3 | |
| # Do all the same steps as the above code, but all at once under the architecture | |
| - uses: uraimo/run-on-arch-action@v3 | |
| name: Build on arch | |
| with: | |
| arch: ${{ matrix.arch }} | |
| distro: ${{ matrix.distro }} | |
| base_image: ${{ matrix.base_image }} | |
| # Not required, but speeds up builds by storing container images in | |
| # a GitHub package registry. | |
| githubToken: ${{ github.token }} | |
| # Perform the installation in a cached state to speed up subsequent builds | |
| install: | | |
| apt-get update | |
| apt-get install curl -y | |
| curl -s --compressed -o /usr/share/keyrings/ctr-pubkey.gpg "https://deb.ctr-electronics.com/ctr-pubkey.gpg" | |
| curl -s --compressed -o /etc/apt/sources.list.d/ctr2026.list "https://deb.ctr-electronics.com/ctr2026.list" | |
| apt-get update | |
| apt-get install phoenix6 cmake build-essential libsdl2-dev -y | |
| # Perform the necesary steps to build the example | |
| run: | | |
| mkdir build | |
| cd build | |
| cmake .. | |
| make | |
| timeout 10s ./Phoenix6-Example || ( [[ $? -eq 124 ]] && echo "Program started successfully" ) |