|
| 1 | +name: One fallback attribution capture |
| 2 | +on: |
| 3 | + push: |
| 4 | + branches: [codex/fallback-attribution-35749f4] |
| 5 | +permissions: |
| 6 | + contents: read |
| 7 | +jobs: |
| 8 | + capture: |
| 9 | + runs-on: ubuntu-26.04 |
| 10 | + timeout-minutes: 20 |
| 11 | + steps: |
| 12 | + - name: Retain initial envelope before checkout or runtime setup |
| 13 | + run: | |
| 14 | + mkdir -p "$RUNNER_TEMP/fallback-capture/evidence" |
| 15 | + printf '{"schema":"fallback-initial.v1","consumerExecutions":0,"status":"before-checkout-and-setup","envelope":"%s","run":"%s","attempt":"%s","image":"%s","runner":"%s"}\n' "$GITHUB_SHA" "$GITHUB_RUN_ID" "$GITHUB_RUN_ATTEMPT" "$ImageVersion" "$RUNNER_NAME" > "$RUNNER_TEMP/fallback-capture/evidence/initial-manifest.json" |
| 16 | + uname -a > "$RUNNER_TEMP/fallback-capture/evidence/initial-uname.txt" |
| 17 | + cat /etc/os-release > "$RUNNER_TEMP/fallback-capture/evidence/initial-os-release.txt" |
| 18 | + - uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 |
| 19 | + with: |
| 20 | + fetch-depth: 0 |
| 21 | + persist-credentials: false |
| 22 | + - uses: denoland/setup-deno@e95548e56dfa95d4e1a28d6f422fafe75c4c26fb |
| 23 | + with: |
| 24 | + deno-version: v2.9.5 |
| 25 | + - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 |
| 26 | + with: |
| 27 | + node-version: "22.23.4" |
| 28 | + - uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 |
| 29 | + - uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 |
| 30 | + with: |
| 31 | + bun-version: 1.4.0 |
| 32 | + - name: Admit runner, prepare exact product once, then instrument |
| 33 | + run: | |
| 34 | + runner_binary="$(readlink -f "/proc/$PPID/exe")" |
| 35 | + printf '%s\n' "$runner_binary" > "$RUNNER_TEMP/fallback-capture/evidence/runner-worker-path.txt" |
| 36 | + export CAPTURE_RUNNER_VERSION="$("$(dirname "$runner_binary")/Runner.Listener" --version)" |
| 37 | + deno run --allow-all --node-modules-dir=none --frozen scripts/fallback-capture-deno.ts prepare |
| 38 | + - name: Capture the complete consumer exactly once |
| 39 | + timeout-minutes: 6 |
| 40 | + run: deno run --allow-all --node-modules-dir=none --frozen scripts/fallback-capture-deno.ts consume |
| 41 | + - name: Retain partial evidence after every terminal outcome |
| 42 | + if: always() |
| 43 | + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a |
| 44 | + with: |
| 45 | + name: fallback-capture-35749f4-${{ github.run_id }}-attempt-${{ github.run_attempt }} |
| 46 | + path: ${{ runner.temp }}/fallback-capture/evidence |
| 47 | + include-hidden-files: true |
| 48 | + if-no-files-found: error |
0 commit comments