Garry's Opinionated OpenClaw/Hermes Agent Brain
TypeScript
fix(ci): install curl in the ci:local runner so check:vendor-postgres runs (#7765)
garrytan91e3bd209e4b
diff --git a/scripts/ci-local.sh b/scripts/ci-local.shindex e7a0cb36fa..7fe8fe9527 100755--- a/scripts/ci-local.sh+++ b/scripts/ci-local.sh@@ -272,16 +272,18 @@ echo "[runner] bun version: $(bun --version)"# Test prerequisites may be missing even in a warm runner image: git backs# fixture repos, python3 backs security scans and argv recorders, and ps backs# live-process / PID-reuse lock checks. psql cleans up connections between E2E-# files. None are application dependencies.+# files. curl downloads for check:vendor-postgres (vendor/update-postgres.sh);+# the oven/bun image ships without it (#7765). None are application dependencies.if ! command -v git >/dev/null 2>&1 || \! command -v python3 >/dev/null 2>&1 || \! command -v ps >/dev/null 2>&1 || \! command -v psql >/dev/null 2>&1 || \! command -v cc >/dev/null 2>&1 || \- ! command -v jq >/dev/null 2>&1; then+ ! command -v jq >/dev/null 2>&1 || \+ ! command -v curl >/dev/null 2>&1; thenecho "[runner] Installing test prerequisites (debian apt)..."apt-get update -qq >/dev/null- apt-get install -y -qq git ca-certificates python3 procps postgresql-client jq build-essential >/dev/null+ apt-get install -y -qq git ca-certificates python3 procps postgresql-client jq curl build-essential >/dev/nullfi# Container runs as root (uid 0) against a host-uid bind-mount; mark repo +# any worktree gitdir as safe so `git status` etc. don't refuse.diff --git a/test/scripts/ci-local-rendering.test.ts b/test/scripts/ci-local-rendering.test.tsindex b2ef68c0f8..965fc50309 100644--- a/test/scripts/ci-local-rendering.test.ts+++ b/test/scripts/ci-local-rendering.test.ts@@ -36,10 +36,12 @@ test('the runner compiles its own CLI and avoids GNU-only xargs flags', () => {});describe('ci-local command rendering', () => {+ // Every tool the runner's prerequisite gate checks; curl backs check:vendor-postgres (#7765).+ const prerequisites = ['git', 'python3', 'ps', 'psql', 'cc', 'jq', 'curl'];const cases = [{ phaseExit: 0, missingTool: '' },{ phaseExit: 7, missingTool: '' },- ...['git', 'python3', 'ps', 'psql', 'cc', 'jq'].map(missingTool => ({ phaseExit: 0, missingTool })),+ ...prerequisites.map(missingTool => ({ phaseExit: 0, missingTool })),];for (const { phaseExit, missingTool } of cases) {test(`preserves stderr and exit ${phaseExit}; missing prerequisite ${missingTool || 'none'}`, () => {@@ -51,7 +53,7 @@ describe('ci-local command rendering', () => {mkdirSync(bin);// Execute the actual runner template, with installation/configuration// commands stubbed so this regression needs neither Docker nor root.- for (const name of ['bun', 'git', 'python3', 'ps', 'psql', 'cc', 'jq']) {+ for (const name of ['bun', ...prerequisites]) {writeFileSync(join(bin, name), '#!/bin/sh\nexit 0\n', { mode: 0o755 });}writeFileSync(join(bin, 'apt-get'), '#!/bin/sh\nprintf "%s\\n" "$*" >> "$INSTALL_LOG"\n', { mode: 0o755 });@@ -88,7 +90,7 @@ describe('ci-local command rendering', () => {expect(result.stdout.includes('phase completed')).toBe(phaseExit === 0);expect(existsSync(join(home, '__RUN_PHASES__1'))).toBe(false);if (missingTool) {- expect(readFileSync(installLog, 'utf8')).toBe('update -qq\ninstall -y -qq git ca-certificates python3 procps postgresql-client jq build-essential\n');+ expect(readFileSync(installLog, 'utf8')).toBe('update -qq\ninstall -y -qq git ca-certificates python3 procps postgresql-client jq curl build-essential\n');} else {expect(existsSync(installLog)).toBe(false);}