GitLab CI
Environment variables
The Authentication environment variables can be configured with Protected variables.
Note: Make sure to configure your release branch as protected in order for the CI/CD build to access the protected variables.
npm provenance
Since GitLab CI is a supported provider for npm provenance, it is recommended to enable this to increase supply-chain security for your npm packages. Find more detail about configuring npm to publish with provenance through semantic-release in the documentation for our npm plugin.
Node project configuration
GitLab CI supports Pipelines allowing to test on multiple Node versions and publishing a release only when all test pass.
Note: The publish pipeline must run a Node version that meets our version requirement.
.gitlab-ci.yml
configuration for Node projects
.gitlab-ci.yml
configuration for Node projectsThis example is a minimal configuration for semantic-release with a build running Node 10 and 12. See GitLab CI - Configuration of your jobs with .gitlab-ci.yml
for additional configuration options.
Note: Thesemantic-release
execution command varies depending on whether you are using a local or global semantic-release installation.
.gitlab-ci.yml
configuration for all projects
.gitlab-ci.yml
configuration for all projectsThis example is a minimal configuration for semantic-release with a build running Node 10 and 12. See GitLab CI - Configuration of your jobs with .gitlab-ci.yml
for additional configuration options.
Note: Thesemantic-release
execution command varies depending if you are using a local or global semantic-release installation.
package.json
configuration
package.json
configurationA package.json
is required only for local semantic-release installation.
Last updated