github: generate target list

This commit is contained in:
Ramon Roche
2022-02-01 21:23:11 -08:00
parent 419c849a8e
commit 854d529c81
+12 -5
View File
@@ -74,6 +74,7 @@ jobs:
run: echo ${{ steps.docker_build.outputs.digest }}
enumerate_targets:
name: Generate target list
runs-on: ubuntu-latest
needs: build_docker
outputs:
@@ -83,20 +84,26 @@ jobs:
- name: Checkout Code
uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: 3.7
- name: Install Python packages
run: pip install kconfiglib
- id: set-matrix
name: Get all nuttx targets
run: echo "::set-output name=matrix::$(./Tools/generate_board_targets_json.py -a)"
build_px4:
name: Build targets with Docker
runs-on: ubuntu-latest
needs: enumerate_targets
strategy:
matrix: ${{ fromJson(needs.enumerate_targets.outputs.matrix) }}
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Get container from artifacts
uses: actions/download-artifact@v2
with:
@@ -105,9 +112,9 @@ jobs:
- name: Load Docker image
run: |
docker load --input /tmpt/px4image.tar
docker load --input /tmp/px4image.tar
docker image ls -a
- name: Build the world
run: |
DOCKER_TAG="px4io/px4-dev:${{ env.TAG_NAME }}" ./Tools/docker.run.sh make ${{ matrix.target }}
DOCKER_TAG="${{ env.TAG_NAME }}" ./Tools/docker.run.sh make ${{ matrix.target }}