Skip to content

ci: debug on a single matrix element #37

ci: debug on a single matrix element

ci: debug on a single matrix element #37

name: Build all targets
on:
push:
branches:
- 'mrpollo/ci_runner_groups'
jobs:
group_targets:
runs-on: [runs-on,runner=2cpu-linux-x64,image=ubuntu22-full-x64,"run-id=${{ github.run_id }}"]
container:
image: px4io/px4-dev-base-focal:2021-09-08
options: --user 1001
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
timestamp: ${{ steps.set-timestamp.outputs.timestamp }}
steps:
- uses: actions/checkout@v4
# token: ${{ secrets.ACCESS_TOKEN }}
- id: set-matrix
run: echo "::set-output name=matrix::$(./Tools/generate_board_targets_json.py --group)"
# - name: debug groups
# run: |
# echo "::group::DebugTargets"
# ./Tools/generate_board_targets_json.py --group --verbose
# echo "::endgroup::"
- id: set-timestamp
run: echo "::set-output name=timestamp::$(date +"%Y%m%d%H%M%S")"
setup:
name: ${{ matrix.group }}
runs-on: [runs-on,runner=8cpu-linux-x64,image=ubuntu22-full-x64,"run-id=${{ github.run_id }}"]
needs: group_targets
strategy:
# matrix: ${{ fromJson(needs.group_targets.outputs.matrix) }}
matrix:
include:
- group: 'nuttx-px4'
targets: 'px4_fmu-v5x_default,px4_fmu-v6x_default'
container: 'px4io/px4-dev-nuttx-focal:2022-08-12'
arch: 'nuttx'
container:
image: ${{ matrix.container }}
options: --user 1001
steps:
- uses: actions/checkout@v4
with:
submodules: true
# token: ${{ secrets.ACCESS_TOKEN }}
- name: debug permissions
run: |
echo "::group::DebugPermissions"
echo $UID
echo $PATH
echo "::endgroup::"
- name: ccache setup keys
uses: actions/cache@v4
with:
path: ~/.ccache
key: ${{ matrix.arch }}-ccache-${{ needs.group_targets.outputs.timestamp }}
restore-keys: ${{ matrix.arch }}-ccache-${{ needs.group_targets.outputs.timestamp }}
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 120M" >> ~/.ccache/ccache.conf
echo "hash_dir = false" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: Debug with tmate session
uses: mxschmitt/action-tmate@v3
with:
detached: true
- name: build target group
run: |
./Tools/ci_build_all_runner.sh ${{matrix.targets}}
- name: ccache post-run
run: ccache -s