Deployment and Software Supply Chain Security

A release includes code from your team, dependencies from other maintainers, and the configuration of the build and hosting systems. Each can change what reaches users.

On this page

Review what enters the build

Commit the lockfile and review its changes alongside the dependency manifest. In an npm project, npm ci installs from the lockfile and fails if the manifest and lockfile disagree. Review advisories and test upgrades. Inventory direct and transitive packages so you can identify affected releases. A clean advisory report alone cannot establish package integrity.

# Run in the reviewed project checkout with its committed package-lock.json.
npm ci
npm audit

Promote the reviewed artifact

Restrict CI credentials, protect release branches, and keep untrusted changes away from deployment secrets. Build once and verify trusted provenance or signatures before promoting the same artifact. Disable debug output, remove sample accounts, and grant the runtime only its required permissions. For pinned third-party browser assets, Subresource Integrity can verify expected bytes.

Pull request   Review code and lockfile; run checks without deploy credentials
Build          Produce the artifact and trusted provenance
Production     Verify provenance, then deploy the approved artifact

Official references