Skip to content

Ensure npm install and prune aren't affected by NODE_ENV #1153

@colincasey

Description

@colincasey

Right now, during this CNB's build phase, we should guarantee that:

  • all dependencies will be installed before supported scripts in package.json are executed (i.e.; heroku-prebuild, heroku-build or build, heroku-postbuild)
  • dev dependencies are pruned at the end of the CNB build phase so that production images don't contain unnecessary packages

But, with the introduction of npm dev dependency pruning in #1126, the install and prune commands aren't fully isolated from NODE_ENV if it is set which can produce unexpected results (see #1126 (comment)).

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions