From 69edbfb717ca6a50c4fd81b7d986a229ffbe4e6a Mon Sep 17 00:00:00 2001 From: github-ops Date: Fri, 15 May 2026 20:27:03 +0000 Subject: [PATCH] ci: move community actions to self-hosted runners --- .github/workflows/ci.yml | 18 ++++-------------- .github/workflows/deploy.yml | 6 ++---- .github/workflows/release.yml | 13 +++---------- README.md | 5 +++++ 4 files changed, 14 insertions(+), 28 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 584dbfa..342c6c9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,7 +14,7 @@ concurrency: jobs: rust: name: Rust Checks - runs-on: ubuntu-latest + runs-on: [self-hosted, linux, x64] services: postgres: image: postgres:16-alpine @@ -42,9 +42,6 @@ jobs: toolchain: 1.85.0 components: rustfmt, clippy - - name: Cache cargo artifacts - uses: Swatinem/rust-cache@v2 - - name: Check formatting run: cargo fmt --all --check @@ -59,7 +56,7 @@ jobs: ui: name: UI Checks - runs-on: ubuntu-latest + runs-on: [self-hosted, linux, x64] steps: - name: Checkout @@ -69,8 +66,6 @@ jobs: uses: actions/setup-node@v4 with: node-version: 22 - cache: npm - cache-dependency-path: apps/ui/package-lock.json - name: Install UI dependencies working-directory: apps/ui @@ -85,7 +80,7 @@ jobs: frontend-e2e: name: Frontend E2E - runs-on: ubuntu-latest + runs-on: [self-hosted, linux, x64] steps: - name: Checkout @@ -96,15 +91,10 @@ jobs: with: toolchain: 1.85.0 - - name: Cache cargo artifacts - uses: Swatinem/rust-cache@v2 - - name: Setup Node.js uses: actions/setup-node@v4 with: node-version: 22 - cache: npm - cache-dependency-path: apps/ui/package-lock.json - name: Install UI dependencies working-directory: apps/ui @@ -136,7 +126,7 @@ jobs: deployment: name: Deployment Manifests - runs-on: ubuntu-latest + runs-on: [self-hosted, linux, x64] steps: - name: Checkout diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 1e7782c..844ee6c 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -31,7 +31,7 @@ jobs: github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.head_branch == 'main' ) - runs-on: ubuntu-latest + runs-on: [self-hosted, linux, x64] strategy: fail-fast: false matrix: @@ -78,8 +78,6 @@ jobs: tags: | ${{ steps.image.outputs.name }}:${{ env.IMAGE_TAG }} ${{ steps.image.outputs.name }}:main - cache-from: type=gha,scope=${{ matrix.name }} - cache-to: type=gha,mode=max,scope=${{ matrix.name }} deploy: needs: build-images @@ -90,7 +88,7 @@ jobs: github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.head_branch == 'main' ) - runs-on: ubuntu-latest + runs-on: [self-hosted, linux, x64] steps: - name: Checkout diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 90edca9..4d4a82d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -22,7 +22,7 @@ env: jobs: build-release-assets: - runs-on: ubuntu-latest + runs-on: [self-hosted, linux, x64] steps: - name: Checkout @@ -33,15 +33,10 @@ jobs: with: toolchain: 1.85.0 - - name: Cache cargo artifacts - uses: Swatinem/rust-cache@v2 - - name: Setup Node.js uses: actions/setup-node@v4 with: node-version: 22 - cache: npm - cache-dependency-path: apps/ui/package-lock.json - name: Build release binaries run: cargo build --release -p admin-api -p mcp-server @@ -86,7 +81,7 @@ jobs: dist/crank-community-${{ env.IMAGE_TAG }}-sbom.spdx.json publish-images: - runs-on: ubuntu-latest + runs-on: [self-hosted, linux, x64] strategy: fail-fast: false matrix: @@ -124,14 +119,12 @@ jobs: tags: | ${{ matrix.image }}:${{ env.IMAGE_TAG }} ${{ matrix.image }}:latest - cache-from: type=gha,scope=release-${{ matrix.name }} - cache-to: type=gha,mode=max,scope=release-${{ matrix.name }} github-release: needs: - build-release-assets - publish-images - runs-on: ubuntu-latest + runs-on: [self-hosted, linux, x64] steps: - name: Download release artifacts diff --git a/README.md b/README.md index 8d014e4..ec103bb 100644 --- a/README.md +++ b/README.md @@ -96,6 +96,11 @@ Crank - платформа для публикации внешних API в в - `CD`, который после успешного `CI` на `main` собирает versioned images, пушит их в `GHCR` и деплоит Community через `deploy/community/docker-compose.yml`; - containerized Community deployment через `deploy/community/docker-compose.yml`. +Важно: + +- GitHub Actions в этом репозитории рассчитаны только на `self-hosted` runner; +- `ubuntu-latest`, `actions/cache` и `type=gha` intentionally не используются, чтобы не тратить платные GitHub-hosted минуты и cache quota на private repository. + ## Поддерживаемые протоколы В целевой модели платформа ориентируется на: