文档对齐实现:CLI 认证机制、逐实例隔离与实例键 #55
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - main | |
| permissions: | |
| contents: read | |
| jobs: | |
| host-agent: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| persist-credentials: false | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: "22" | |
| cache: npm | |
| cache-dependency-path: host-agent/package-lock.json | |
| - name: Ticket vectors match the generator | |
| run: python3 tests/vectors/generate.py --check | |
| - name: Install | |
| working-directory: host-agent | |
| run: npm ci --no-fund --no-audit | |
| - name: Typecheck | |
| working-directory: host-agent | |
| run: npm run typecheck | |
| - name: Test | |
| working-directory: host-agent | |
| run: npm test | |
| - name: Build bundle | |
| working-directory: host-agent | |
| run: npm run build | |
| image: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 30 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| persist-credentials: false | |
| - uses: docker/setup-buildx-action@v3 | |
| - name: Docker build (no push) | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| file: Dockerfile | |
| push: false | |
| platforms: linux/amd64 | |
| chart: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| persist-credentials: false | |
| - uses: azure/setup-helm@v4 | |
| with: | |
| version: v3.16.4 | |
| - name: Lint chart | |
| run: helm lint deploy | |
| - name: Render chart | |
| run: helm template computer-host deploy -f deploy/ci/values-ci.yaml > /tmp/computer-host.yaml | |
| - name: Required objects are present | |
| run: | | |
| set -euo pipefail | |
| for kind in Secret PersistentVolumeClaim Deployment Service Ingress; do | |
| grep -q "^kind: ${kind}$" /tmp/computer-host.yaml | |
| done | |
| grep -q "COMPUTER_TICKET_SECRET" /tmp/computer-host.yaml | |
| grep -q "path: /__healthz" /tmp/computer-host.yaml |