diff --git a/.github/workflows/build-dev-container.yaml b/.github/workflows/build-dev-container.yaml index a834904..9d44606 100644 --- a/.github/workflows/build-dev-container.yaml +++ b/.github/workflows/build-dev-container.yaml @@ -7,39 +7,59 @@ on: # rebuild any PRs and main branch changes jobs: - list-folders: - runs-on: ubuntu-latest + find-jobs: + name: Find Jobs + container: debian:buster-slim + outputs: + folders: ${{ steps.jobs.outputs.folders }} steps: - - uses: philips-labs/list-folder-action@v1 + - uses: actions/checkout@v1 + + - id: jobs + uses: philips-labs/list-folders-action@v1 with: - directory: ./templates - - build: - runs-on: ubuntu-latest + path: ./templates + + matrix: + name: Matrix Jobs + needs: [find-jobs] + container: ubuntu + defaults: + run: + working-directory: ${{ matrix.folder }} strategy: matrix: - subfolder: ${{ fromJSON(needs.list-folders.outputs.folders) }} + folder: ${{ fromJson(needs.find-jobs.outputs.folders )}} steps: - - name: Checkout - uses: actions/checkout@v4 + - 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 QEMU + # uses: docker/setup-qemu-action@v3 - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@f95db51fddba0c2d1ec667646a06c2ce06100226 + # - 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: 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/ci@v0.3 - with: - subFolder: ./templates/${{ matrix.subfolder }} - imageName: ghcr.io/pnstack/codespace/${{ matrix.subfolder }} - platform: linux/amd64,linux/arm64 - push: always \ No newline at end of file + # - name: Build and run Dev Container task + # uses: devcontainers/ci@v0.3 + # with: + # subFolder: ./templates/${{ matrix.subfolder }} + # imageName: ghcr.io/pnstack/codespace/${{ matrix.subfolder }} + # platform: linux/amd64,linux/arm64 + # push: always \ No newline at end of file