The NPM plugin can be used to publish libraries to public or private registries. The below pipeline configuration demonstrates simple usage:
pipeline: npm: image: plugins/npm username: bob password: password email: firstname.lastname@example.org
Example configuration using a custom registry:
pipeline: npm: image: plugins/npm username: bob password: password email: email@example.com + registry: "http://myregistry:4873"
NPM Enterprise Authentication
NPM enterprise users can optionally authenticate using authorization tokens. The token will always override the username and password authentication method.
pipeline: npm: image: plugins/npm - username: bob - password: password + token: f0e4c2f76c58916ec25 email: firstname.lastname@example.org
- the username for the account to publish with
- the password for the account to publish with
- the deploy token to publish with
- the email address associated with the account to publish with.
- the registry URL. defaults to https://registry.npmjs.org.
- the folder, relative to the workspace, containing the library. defaults to the workspace directory.