mirror of
https://github.com/openclaw/openclaw.git
synced 2026-07-24 06:11:12 +00:00
ci: bound Blacksmith sticky disk growth (#109934)
This commit is contained in:
committed by
GitHub
parent
e316e1c440
commit
00a64f6e95
10
.github/workflows/ci.yml
vendored
10
.github/workflows/ci.yml
vendored
@@ -1021,10 +1021,6 @@ jobs:
|
||||
# repository-global state and must never be produced by fork code.
|
||||
sticky-disk: ${{ github.event_name != 'workflow_dispatch' && github.repository == 'openclaw/openclaw' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'openclaw/openclaw') && 'true' || 'false' }}
|
||||
use-actions-cache: ${{ github.event_name != 'workflow_dispatch' && github.repository == 'openclaw/openclaw' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'openclaw/openclaw') && 'false' || 'true' }}
|
||||
# Designated dependency-snapshot writer: exactly one trusted-push job
|
||||
# per node-version key refreshes the protected disk; every other
|
||||
# sticky consumer mounts read-only.
|
||||
save-sticky-disk: "true"
|
||||
runtime-cache-sticky-disk: ${{ github.event_name != 'workflow_dispatch' && github.repository == 'openclaw/openclaw' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'openclaw/openclaw') && 'true' || 'false' }}
|
||||
save-node-compile-cache: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' && 'true' || 'false' }}
|
||||
|
||||
@@ -1827,9 +1823,9 @@ jobs:
|
||||
# Blacksmith same-repo runs clone dependencies from a sticky disk.
|
||||
# Fork PRs must keep actions/cache: sticky snapshots are writable,
|
||||
# repository-global state and must never be produced by fork code.
|
||||
sticky-disk: ${{ github.event_name != 'workflow_dispatch' && github.repository == 'openclaw/openclaw' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'openclaw/openclaw') && 'true' || 'false' }}
|
||||
runtime-cache-sticky-disk: ${{ github.event_name != 'workflow_dispatch' && github.repository == 'openclaw/openclaw' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'openclaw/openclaw') && 'true' || 'false' }}
|
||||
use-actions-cache: ${{ github.event_name != 'workflow_dispatch' && github.repository == 'openclaw/openclaw' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'openclaw/openclaw') && 'false' || 'true' }}
|
||||
sticky-disk: ${{ (matrix.node_version == null || matrix.node_version == '24.x') && github.event_name != 'workflow_dispatch' && github.repository == 'openclaw/openclaw' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'openclaw/openclaw') && 'true' || 'false' }}
|
||||
runtime-cache-sticky-disk: ${{ (matrix.node_version == null || matrix.node_version == '24.x') && github.event_name != 'workflow_dispatch' && github.repository == 'openclaw/openclaw' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'openclaw/openclaw') && 'true' || 'false' }}
|
||||
use-actions-cache: ${{ (matrix.node_version == null || matrix.node_version == '24.x') && github.event_name != 'workflow_dispatch' && github.repository == 'openclaw/openclaw' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == 'openclaw/openclaw') && 'false' || 'true' }}
|
||||
vitest-fs-cache: "true"
|
||||
node-compile-cache: "true"
|
||||
node-compile-cache-scope: "test"
|
||||
|
||||
25
.github/workflows/vitest-cache-warm.yml
vendored
25
.github/workflows/vitest-cache-warm.yml
vendored
@@ -5,6 +5,10 @@ on:
|
||||
types: [vitest-cache-warm]
|
||||
schedule:
|
||||
- cron: "17 8 * * *"
|
||||
workflow_run: # zizmor: ignore[dangerous-triggers] successful main-push CI only; read-only default-branch checkout, no artifacts or untrusted ref
|
||||
workflows: [CI]
|
||||
branches: [main]
|
||||
types: [completed]
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
@@ -15,7 +19,7 @@ concurrency:
|
||||
|
||||
jobs:
|
||||
warm:
|
||||
if: github.repository == 'openclaw/openclaw'
|
||||
if: github.repository == 'openclaw/openclaw' && (github.event_name != 'workflow_run' || (github.event.workflow_run.event == 'push' && github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.head_branch == 'main'))
|
||||
runs-on: blacksmith-8vcpu-ubuntu-2404
|
||||
timeout-minutes: 30
|
||||
steps:
|
||||
@@ -26,21 +30,21 @@ jobs:
|
||||
uses: ./.github/actions/setup-node-env
|
||||
with:
|
||||
install-bun: "false"
|
||||
node-compile-cache: "true"
|
||||
node-compile-cache: ${{ github.event_name != 'workflow_run' && 'true' || 'false' }}
|
||||
node-compile-cache-scope: "test"
|
||||
runtime-cache-sticky-disk: "true"
|
||||
save-node-compile-cache: "true"
|
||||
# Daily deadline writer for the protected dependency snapshot:
|
||||
# canonical main pushes cancel each other under merge traffic, so
|
||||
# build-artifacts commits can starve; this scheduled run cannot be
|
||||
# superseded and keeps the snapshot within a day of main.
|
||||
runtime-cache-sticky-disk: ${{ github.event_name != 'workflow_run' && 'true' || 'false' }}
|
||||
save-node-compile-cache: ${{ github.event_name != 'workflow_run' && 'true' || 'false' }}
|
||||
# This disposable, non-cancelled workflow is the sole dependency
|
||||
# snapshot writer. Main CI completion coalesces refreshes without
|
||||
# putting required build jobs in a cancel-on-pending mutex.
|
||||
save-sticky-disk: "true"
|
||||
save-vitest-fs-cache: "true"
|
||||
save-vitest-fs-cache: ${{ github.event_name != 'workflow_run' && 'true' || 'false' }}
|
||||
sticky-disk: "true"
|
||||
use-actions-cache: "false"
|
||||
vitest-fs-cache: "true"
|
||||
vitest-fs-cache: ${{ github.event_name != 'workflow_run' && 'true' || 'false' }}
|
||||
|
||||
- name: Select broad cache seed
|
||||
if: github.event_name != 'workflow_run'
|
||||
shell: bash
|
||||
run: |
|
||||
set -euo pipefail
|
||||
@@ -68,4 +72,5 @@ jobs:
|
||||
EOF
|
||||
|
||||
- name: Warm transform and compile caches
|
||||
if: github.event_name != 'workflow_run'
|
||||
run: node scripts/ci-run-node-test-shard.mjs
|
||||
|
||||
Reference in New Issue
Block a user