Skip to content

Commit be6dbc4

Browse files
B4nanclaude
andauthored
ci: use standalone apify-cli binary in E2E tests (apify#3543)
## Summary - Replace `npx -y apify-cli@beta` with a standalone binary downloaded from `apify/apify-cli` GitHub releases - `npx -y` resolves transitive deps fresh from npm without a lockfile, which exposed CI to the recent `axios@1.14.1` supply chain compromise — the E2E run at 2026-03-31T03:02Z attempted to install it - The standalone binary bundles all deps at build time, so no npm resolution happens during CI 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 863dbca commit be6dbc4

2 files changed

Lines changed: 8 additions & 4 deletions

File tree

.github/workflows/test-e2e.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,11 +53,15 @@ jobs:
5353
restore-keys: |
5454
turbo-${{ github.job }}-${{ github.ref_name }}-
5555
56-
- name: Login to Apify
57-
run: npx -y apify-cli@beta login -t ${{ secrets.APIFY_SCRAPER_TESTS_API_TOKEN }}
56+
57+
- name: Setup Apify CLI
58+
uses: apify/setup-apify-cli-action@main
59+
with:
60+
version: 'beta'
61+
token: ${{ secrets.APIFY_SCRAPER_TESTS_API_TOKEN }}
5862

5963
- name: Add Apify secrets for E2E tests
60-
run: npx -y apify-cli@beta secrets add anthropicApiKey ${{ secrets.ANTHROPIC_API_KEY }}
64+
run: apify secrets add anthropicApiKey ${{ secrets.ANTHROPIC_API_KEY }}
6165

6266
- name: Install Dependencies
6367
run: yarn

test/e2e/tools.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ export function getActorTestDir(url) {
7171
export async function pushActor(client, dirName) {
7272
await copyPackages(dirName);
7373
try {
74-
execSync('npx -y apify-cli@beta push', {
74+
execSync('apify push', {
7575
cwd: dirName,
7676
env: { ...process.env, GIT_CEILING_DIRECTORIES: dirname(dirName) },
7777
});

0 commit comments

Comments
 (0)