fix: ci
Some checks failed
ci / build-ui (push) Failing after 4s
ci / test (push) Failing after 9s
ci / publish (push) Has been skipped

This commit is contained in:
Matthew McPeak 2026-06-17 15:31:24 -04:00
parent 034cd4df8c
commit d9d9c033bb
Signed by: McPeakML
GPG key ID: 3D64A2E70F58D07C

View file

@ -1,89 +1,94 @@
name: ci name: ci
on: on:
push: push:
tags: tags:
- 'v*' - "v*"
pull_request: pull_request:
jobs: jobs:
test: test:
runs-on: self-hosted runs-on: self-hosted
container: git.mcpeakdev.com/mcpeakdev/rust-ci:latest container: git.mcpeakdev.com/mcpeakdev/rust-ci:latest
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Cache cargo registry - name: Cache cargo registry
uses: actions/cache@v4 uses: actions/cache@v4
with: with:
path: | path: |
~/.cargo/registry ~/.cargo/registry
~/.cargo/git ~/.cargo/git
target target
key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }} key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }}
restore-keys: | restore-keys: |
${{ runner.os }}-cargo- ${{ runner.os }}-cargo-
- name: Check formatting - name: Check formatting
run: cargo fmt --check run: cargo fmt --check
- name: Clippy - name: Clippy
run: cargo clippy -- -D warnings run: cargo clippy -- -D warnings
- name: Run tests - name: Run tests
run: cargo test run: cargo test
build-ui: build-ui:
runs-on: self-hosted runs-on: self-hosted
container: git.mcpeakdev.com/mcpeakdev/bun-ci:latest container: git.mcpeakdev.com/mcpeakdev/bun-ci:latest
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Install dependencies - name: Inject bunfig.toml
run: bun install --frozen-lockfile run: printf '[install.scopes]\n"@nychthemeron" = { token = "${BUN_AUTH_TOKEN}", url = "https://git.mcpeakdev.com/api/packages/McPeakDev/npm/" }\n' > /root/.bunfig.toml
working-directory: ui env:
BUN_AUTH_TOKEN: ${{ secrets.BUN_AUTH_TOKEN }}
- name: Audit dependencies - name: Install dependencies
run: bun audit || true run: bun install --frozen-lockfile
working-directory: ui working-directory: ui
- name: Type check - name: Audit dependencies
run: bun run build run: bun audit || true
working-directory: ui working-directory: ui
publish: - name: Type check
needs: [test, build-ui] run: bun run build
if: startsWith(github.ref, 'refs/tags/v') working-directory: ui
runs-on: self-hosted
container: git.mcpeakdev.com/mcpeakdev/docker-pub:latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Docker Buildx publish:
uses: docker/setup-buildx-action@v3 needs: [test, build-ui]
if: startsWith(github.ref, 'refs/tags/v')
runs-on: self-hosted
container: git.mcpeakdev.com/mcpeakdev/docker-pub:latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Log in to registry - name: Set up Docker Buildx
uses: docker/login-action@v3 uses: docker/setup-buildx-action@v3
with:
registry: git.mcpeakdev.com
username: ${{ github.actor }}
password: ${{ secrets.FORGEJO_TOKEN }}
- name: Extract image tag - name: Log in to registry
id: meta uses: docker/login-action@v3
run: echo "tag=${GITHUB_REF_NAME#v}" >> "$GITHUB_OUTPUT" with:
registry: git.mcpeakdev.com
username: ${{ github.actor }}
password: ${{ secrets.FORGEJO_TOKEN }}
- name: Build and push - name: Extract image tag
uses: docker/build-push-action@v6 id: meta
with: run: echo "tag=${GITHUB_REF_NAME#v}" >> "$GITHUB_OUTPUT"
context: .
file: Dockerfile - name: Build and push
push: true uses: docker/build-push-action@v6
tags: | with:
git.mcpeakdev.com/mcpeakdev/mercury:${{ steps.meta.outputs.tag }} context: .
git.mcpeakdev.com/mcpeakdev/mercury:latest file: Dockerfile
cache-from: type=registry,ref=git.mcpeakdev.com/mcpeakdev/mercury:latest push: true
cache-to: type=inline tags: |
git.mcpeakdev.com/mcpeakdev/mercury:${{ steps.meta.outputs.tag }}
git.mcpeakdev.com/mcpeakdev/mercury:latest
cache-from: type=registry,ref=git.mcpeakdev.com/mcpeakdev/mercury:latest
cache-to: type=inline