feat: Add find-jobs step to build-dev-container.yaml #14
This file contains 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: 'Build dev container' | ||
on: # rebuild any PRs and main branch changes | ||
pull_request: | ||
push: | ||
branches: | ||
- master | ||
jobs: | ||
find-jobs: | ||
name: Find Jobs | ||
Check failure on line 11 in .github/workflows/build-dev-container.yaml GitHub Actions / Build dev containerInvalid workflow file
|
||
container: debian:buster-slim | ||
outputs: | ||
folders: ${{ steps.jobs.outputs.folders }} | ||
steps: | ||
- uses: actions/checkout@v1 | ||
- id: jobs | ||
uses: philips-labs/list-folders-action@v1 | ||
with: | ||
path: ./templates | ||
matrix: | ||
name: Matrix Jobs | ||
needs: [find-jobs] | ||
container: ubuntu | ||
defaults: | ||
run: | ||
working-directory: ${{ matrix.folder }} | ||
strategy: | ||
matrix: | ||
folder: ${{ fromJson(needs.find-jobs.outputs.folders )}} | ||
steps: | ||
- name: do something | ||
run: echo ${{ matrix.folder }} | ||
# build: | ||
# runs-on: ubuntu-latest | ||
# strategy: | ||
# matrix: | ||
# subfolder: ${{ fromJSON(needs.list-folders.outputs.folders) }} | ||
# steps: | ||
# - name: Checkout | ||
# uses: actions/checkout@v4 | ||
# - name: Set up QEMU | ||
# uses: docker/setup-qemu-action@v3 | ||
# - name: Set up Docker Buildx | ||
# uses: docker/setup-buildx-action@f95db51fddba0c2d1ec667646a06c2ce06100226 | ||
# - name: Login to GitHub Container Registry | ||
# uses: docker/login-action@v2 | ||
# with: | ||
# registry: ghcr.io | ||
# username: ${{ github.repository_owner }} | ||
# password: ${{ secrets.GITHUB_TOKEN }} | ||
# - name: Build and run Dev Container task | ||
# uses: devcontainers/[email protected] | ||
# with: | ||
# subFolder: ./templates/${{ matrix.subfolder }} | ||
# imageName: ghcr.io/pnstack/codespace/${{ matrix.subfolder }} | ||
# platform: linux/amd64,linux/arm64 | ||
# push: always |