fix: add --ignore-scripts to pnpm install in Dockerfile.ecs#5252
Open
dhaley wants to merge 2 commits into
Open
fix: add --ignore-scripts to pnpm install in Dockerfile.ecs#5252dhaley wants to merge 2 commits into
dhaley wants to merge 2 commits into
Conversation
pnpm-workspace.yaml (added in v3.4.0) includes ng_seed/seed-angular as a workspace package. seed-angular's preinstall hook runs `npx -y only-allow pnpm` which uses npm as the exec agent internally — only-allow detects this and rejects the install with exit code 1. Adding --ignore-scripts to the initial pnpm install skips lifecycle hooks during dependency installation. The Angular build is then run explicitly via `pnpm -C /seed/ng_seed/seed-angular build` in the next step.
Dockerfile.ecs.ci is identical to Dockerfile.ecs but omits the NREL internal cert fetch (raw.github.nrel.gov is unreachable from public GitHub runners). The new ecs-docker-build CI job catches regressions like the pnpm workspace preinstall failure introduced in v3.4.0 (fixed in this PR via --ignore-scripts) that would otherwise only surface during a CodeBuild deploy.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
pnpm-workspace.yamladded in #5126 (v3.4.0) includesng_seed/seed-angularas a workspace package.seed-angular'spreinstallhook runsnpx -y only-allow pnpm, butnpxusesnpmas its exec agent internally —only-allowdetects this and rejects the install:This broke
Dockerfile.ecson thedevelopbranch. Last working commit:41cbf544c(v3.3.2).Fix
Add
--ignore-scriptsto the initialpnpm installinDockerfile.ecs. Lifecycle hooks aren't needed during dependency installation — the Angular build is already run explicitly in the next step viapnpm -C /seed/ng_seed/seed-angular build.Testing
The
Dockerfile.ecsbuild now completes successfully with the workspace layout introduced in v3.4.0.