This section of the guide covers best practices for
dependencies declared in
Where possible, use version ranges instead of pinning to an exact version. The suggested default is to use a patch-level version match:
This will match version
1.2.3 and any patches to that release. In other
~1.2.3 is equivalent to
>= 1.2.3, < 1.3.0
For the complete version matching syntax, please see the semver documentation.
The above versioning constraints will not match on pre-release versions.
version: ~1.2.3 will match
version: ~1.2.4 but not
The following provides a pre-release as well as patch-level matching:
Where possible, use
https:// repository URLs, followed by
If the repository has been added to the repository index file, the repository
name can be used as an alias of URL. Use
@ followed by repository
File URLs (
file://...) are considered a "special case" for charts that are
assembled by a fixed deployment pipeline.
When using downloader plugins the URL scheme will be specific to the plugin. Note, a user of the chart will need to have a plugin supporting the scheme installed to update or build the dependency.
Helm cannot perform dependency management operations on the dependency when the
repository field is left blank. In that case Helm will assume the dependency
is in a sub-directory of the
charts folder with the name being the same as the
name property for the dependency.
Conditions and Tags
Conditions or tags should be added to any dependencies that are optional.
The preferred form of a condition is:
somechart is the chart name of the dependency.
When multiple subcharts (dependencies) together provide an optional or swappable feature, those charts should share the same tags.
For example, if both
memcached together provide performance
optimizations for the main app in the chart, and are required to both be present
when that feature is enabled, then they should both have a tags section like
tags: - webaccelerator
This allows a user to turn that feature on and off with one tag.