split up pipelines

This commit is contained in:
sfja 2026-03-30 10:28:16 +02:00
parent 4f1ab9556a
commit ca00bffc85
9 changed files with 102 additions and 79 deletions

24
.github/workflows/backend.yml vendored Normal file
View File

@ -0,0 +1,24 @@
name: Backend
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
verify:
runs-on: ubuntu-latest
container: sfja/h5-mst-ci:backend-ci
steps:
- uses: actions/checkout@v6
- name: Check
working-directory: ./backend
run: make check
- name: Build
working-directory: ./backend
run: make all
- name: Test
working-directory: ./backend
run: make test

29
.github/workflows/game.yml vendored Normal file
View File

@ -0,0 +1,29 @@
name: Game
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
verify:
runs-on: ubuntu-latest
container: sfja/h5-mst-ci:game-ci
steps:
- uses: actions/checkout@v6
- run: rustup default stable
- name: Check
working-directory: ./game
run: cargo check
- name: Clippy
working-directory: ./game
continue-on-error: true
run: cargo clippy
- name: Build
working-directory: ./game
run: cargo build
- name: Test
working-directory: ./game
run: cargo test

24
.github/workflows/skateboard.yml vendored Normal file
View File

@ -0,0 +1,24 @@
name: Skateboard
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
verify:
runs-on: ubuntu-latest
container: espressif/idf:release-v5.5
steps:
- uses: actions/checkout@v6
- name: Build
shell: bash
working-directory: ./skateboard
# https://github.com/espressif/esp-bsp/blob/master/.github/workflows/build-run-applications.yml
run: |
export IDF_PYTHON_CHECK_CONSTRAINTS=yes
${IDF_PATH}/install.sh --enable-ci
source ${IDF_PATH}/export.sh
idf.py build

View File

@ -1,59 +0,0 @@
name: Verify
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
backend:
runs-on: ubuntu-latest
container: sfja/h5-mst-ci:latest
steps:
- uses: actions/checkout@v6
- name: Check
working-directory: ./backend
run: make check
- name: Build
working-directory: ./backend
run: make all
- name: Test
working-directory: ./backend
run: make test
game:
runs-on: ubuntu-latest
container: sfja/h5-mst-ci:latest
steps:
- uses: actions/checkout@v6
- run: rustup default stable
- name: Check
working-directory: ./game
run: cargo check
- name: Clippy
working-directory: ./game
continue-on-error: true
run: cargo clippy
- name: Build
working-directory: ./game
run: cargo build
- name: Test
working-directory: ./game
run: cargo test
skateboard:
runs-on: ubuntu-latest
container: espressif/idf:release-v5.5
steps:
- uses: actions/checkout@v6
- name: Build
shell: bash
working-directory: ./skateboard
# https://github.com/espressif/esp-bsp/blob/master/.github/workflows/build-run-applications.yml
run: |
export IDF_PYTHON_CHECK_CONSTRAINTS=yes
${IDF_PATH}/install.sh --enable-ci
source ${IDF_PATH}/export.sh
idf.py build

View File

@ -0,0 +1,3 @@
FROM alpine:edge
RUN apk add --no-cache curl build-base clang22-extra-tools mosquitto-dev

10
ci-image/backend/publish.sh Executable file
View File

@ -0,0 +1,10 @@
#!/bin/bash
tag=sfja/h5-mst-ci:backend-ci
set -xe
docker build -t $tag .
docker push $tag

View File

@ -1,5 +1,5 @@
FROM alpine:edge FROM alpine:3.23
RUN apk add --no-cache curl build-base clang22-extra-tools mosquitto-dev sdl3-dev RUN apk add --no-cache curl build-base sdl3-dev
RUN curl https://sh.rustup.rs -sSf \ RUN curl https://sh.rustup.rs -sSf \
| sh -s -- --default-toolchain stable -y | sh -s -- --default-toolchain stable -y

10
ci-image/game/publish.sh Executable file
View File

@ -0,0 +1,10 @@
#!/bin/bash
tag=sfja/h5-mst-ci:game-ci
set -xe
docker build -t $tag .
docker push $tag

View File

@ -1,18 +0,0 @@
#!/bin/bash
version=$1
if [[ $version == "" ]]; then
echo "Please specify version"
echo "./publish.sh <version e.g. 1.0>"
exit 1
fi
tag=sfja/h5-mst-ci:$version
set -xe
docker build -t $tag .
docker push $tag