Ease configuration of values for Helm charts in your IDE
The plugin provides several actions to generate JSON schemas for values of Helm charts.
These schemas can then be used in your IDE to document, validate and auto-complete Helm values.
Plugin allows to configure Helm chart repositories directly from your IDE.
Plugin also allows to update Helm dependencies for Helm charts directly from your IDE.
This requires installation of Helm on your local workstation.
More information: Helm values documentation
Action Refresh JSON schema for current chart is available from Chart.yaml
or values.yaml
.
Action will trigger the following processing:
- clear previously extracted JSON schemas
- download JSON schemas from external JSON schema repositories (unless already downloaded)
Action only attempts to download JSON schemas for each dependency if a repository mapping is defined for the Helm repository of the dependency.
Check dedicated section to configure JSON schema repositories.
A fallback schema is generated if package of chart dependency is missing or invalid.
The description of the fallback schema provides more information on the extract issue. - extract file
values.schema.json
from chart dependencies (if available)
A fallback schema is generated if JSON schema can't be extracted from dependency archive (archive not found, corrupted archive ...).
The description of the fallback schema provides more information on the download issue. - generate aggregated JSON schema
aggregated-values.schema.json
in.idea/helm-values/<chart name>/
Action only aggregates extracted JSON schemas for each dependency if a repository mapping is not defined for the Helm repository of the dependency.
Check dedicated section to configure JSON schema repositories.
The JSON schema aggregated-values.schema.json
is used by default to validate file values.yaml
in the same folder as Chart.yaml
.
Additional JSON schema mappings can be configured
in IntelliJ settings
if required (e.g. for other values files applied after packaging).
Optional file aggregated-values.schema.patch.json
can be created in the base folder of the chart
(same folder as Chart.yaml) to patch aggregated JSON schema.
Since #55 (0.9.0),
optional file aggregated-values.schema.patch.yaml
can be created in the base folder of the chart.
to patch aggregated JSON schema.
If JSON patch file is present, YAML patch file is ignored.
For more information on patch files, check dedicated section on patch for generated JSON schemas.
Action Clear JSON schema for current chart is available from Chart.yaml
or values.yaml
.
Action will trigger the following processing:
- clear previously downloaded JSON schemas for the current chart
- clear previously extracted JSON schemas for the current chart
- clear generated JSON schema for the current chart (
aggregated-values.schema.json
)
Action Update dependencies for current chart is available from Chart.yaml
or values.yaml
.
Action will trigger the following processing:
- update Helm repositories (
helm repo update
) - update dependencies for the current chart (
helm dependency update --skip-refresh
)
Action requires installation of Helm on local workstation and configuration of Helm repositories.
Action Refresh JSON schemas for all charts in project is available from actions search and from "All charts in project" menu.
It will trigger the refresh of JSON schemas for each chart in the project
(i.e. for each file named Chart.yaml
in the project).
Action Clear JSON schema for all charts in project is available from actions search and from "All charts in project" menu.
It will clear JSON schemas for each chart in the project (i.e. for each file named Chart.yaml
in the project).
Action Update dependencies for all charts in project is available from actions search and from "All charts in project" menu.
It will trigger the update of Helm dependencies for each chart in the project (i.e. for each file named Chart.yaml
in the project).
Update of Helm repositories is however only executed once for all charts in project.
Action requires installation of Helm on local workstation and configuration of Helm repositories.
Helm chart repositories can be configured in plugin settings and are automatically pushed to Helm installed on your local workstation when settings are saved.
Each chart repository can be configured with user and password in plugin settings.
A reference chart repository can be defined for each chart repository in plugin settings.
When selected, credentials are inherited from the reference chart repository.
Inherited configuration is displayed in read-only in editor.
💡 credentials are stored securely in IntelliJ password safe.
Each chart repository can be configured with an optional JSON schema repository.
More info on this configuration is provided in next section.
As explained in introduction, plugin can be configured to download JSON schemas from external JSON schema repositories.
Repository mappings can be configured in plugin settings to define JSON schema repository for each Helm repository.
Aggregation actions use the repository key in dependencies of Chart.yaml
to define the JSON schema repository
that must be used to download JSON schemas for each dependency.
Given the following Chart.yaml:
apiVersion: v2
name: my-bundle
version: 0.1.0
dependencies:
- name: another-bundle
version: 0.2.0
repository: "@bundles"
- name: simple-app
version: 0.3.0
repository: "@apps"
- name: thirdparty-chart
version: 0.4.0
repository: "@thirdparty"
The plugin must be configured with following configuration to download JSON schemas for the first 2 dependencies:
Default file names for JSON schemas can be overridden for each repository in plugin settings.
Deprecation notice: globalValuesSchemaFile
is deprecated and will be removed in 1.0.0
.
JSON schema repositories can be secured with basic authentication.
Each schema repository can be configured with user and password in plugin settings.
💡 credentials are stored securely in IntelliJ password safe.
A reference repository mapping can be defined for each repository in plugin settings.
When selected, credentials and schema file names are inherited from the reference repository mapping.
Inherited configuration is displayed in read-only in editor.