semantic-release-helm-with-helmdocs
v2.2.0-helmdocs-1.11.0-alpha-0.1.8
Published
semantic-release plugin to update version and app version and generate documentation in a Helm chart. semantic-release-helm-with-helmdocs plugin was forked from verison 2.2.0 of semantic-release-helm and the version of Helm-Docs that was tested within the
Downloads
68
Readme
semantic-release-helm
This is a plugin for semantic-release. It updates version
and appVersion
of a Helm chart's
Chart.yaml.
The version
is increased according to nextRelease.type
, which can be one of
- major
- premajor
- minor
- preminor
- patch
- prepatch
- prerelease
or null if it's not valid.
The appVersion
is set to nextRelease.version
if onlyUpdateVersion
is false or unset.
BREAKING CHANGE in v2
path
has been renamed to chartPath
to prevent config conflicts.
Examples:
version 0.1.0
appVersion 1.16.0
patch (1.16.0 -> 1.16.1)
New chart version is 0.1.1minor (1.16.0 -> 1.17.0)
New chart version is 0.2.0major (1.16.0 -> 2.0.0)
New chart version is 1.0.0
Configuration
chartPath (required) - string Chart directory, where the Chart.yaml is located.
registry (optional) - string
URI of a container registry.onlyUpdateVersion (optional) - boolean (default: false)
Don't changeappVersion
if this is true. Useful if your chart is in a different git repo than the application.crPublish (optional) - boolean
Enable chart-releaser publishingcrConfigPath (optional) - string
Path to .ct.yaml chart-releaser configuration file.prepareHelmChartDocs (optional) - boolean (default: false) Enable Helm Docs to render the Helm Chart documentation
readmeTemplatePath (optional) - string Path to read the .gotmpl template file for customizing the look of the README.md file
readmeFilePath (optional) - string Path to write the README.md file.
Pass credentials through environment variables accordingly:
export REGISTRY_USERNAME=<USERNAME>
export REGISTRY_PASSWORD=<PASSWORD>
For S3 pass the AWS credentials as environment variables:
export AWS_REGION=<REGION>
export AWS_ACCESS_KEY_ID=<ACCESS_KEY_ID>
export AWS_SECRET_ACCESS_KEY=<SECRET_ACCESS_KEY>
Example
This will update version
and appVersion
in ./chart/Chart.yaml
in addition to generate the helm-chart README.md file at the ./
location.
and push the chart to localhost:5000/repo/chart
. The image will be tagged with the value of version
from
Chart.yaml.
{
"plugins": [
[
"semantic-release-helm-with-helmdocs@2.2.0-helmdocs-1.11.0-alpha-0.1.1.",
{
chartPath: './chart',
registry: 'localhost:5000/repo/chart',
prepareHelmChartDocs: true,
readmeTemplatePath: './',
readmeFilePath: './'
}
]
]
}
S3 Example
The helm-s3 plugin adds support for S3. Check the documentation for additional options
This will update version
in ./chart/Chart.yaml
and push the chart to s3://my-s3-bucket/s3-prefix
. The image will be tagged with the value of version
from
Chart.yaml.
{
"plugins": [
[
"semantic-release-helm",
{
chartPath: './chart',
registry: 's3://my-s3-bucket-repo/s3-prefix',
onlyUpdateVersion: true,
}
]
]
}