CI: run devkitPro build via docker so checkout/actions keep Node
Some checks failed
Build / switch (push) Failing after 5s
Some checks failed
Build / switch (push) Failing after 5s
Job-level devkitpro container made actions/checkout fail (no node). Run make inside docker run on the default ubuntu runner; works with act. Made-with: Cursor
This commit is contained in:
18
.github/workflows/build.yml
vendored
18
.github/workflows/build.yml
vendored
@@ -9,21 +9,23 @@ on:
|
||||
jobs:
|
||||
switch:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: devkitpro/devkita64:latest
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Configure git safe directory
|
||||
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
|
||||
|
||||
# Build inside devkitPro image only. A job-level container would run every
|
||||
# step there and break actions/checkout (needs Node). Same issue with `act`.
|
||||
- name: Compile (Switch .nro)
|
||||
env:
|
||||
DEVKITPRO: /opt/devkitpro
|
||||
run: make -j$(nproc)
|
||||
run: |
|
||||
docker run --rm \
|
||||
-v "${{ github.workspace }}:/work" \
|
||||
-w /work \
|
||||
-e DEVKITPRO=/opt/devkitpro \
|
||||
devkitpro/devkita64:latest \
|
||||
bash -lc 'make -j$(nproc)'
|
||||
|
||||
- name: Upload .nro artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
|
||||
Reference in New Issue
Block a user