When a chart is applied to your cluster a release is created. A chart is nothing but the collection of files.
- When we execute helm create command it will automatically create a directory with the defined name.
- Command: “helm create <PROVIDE_CHART _NAME>
- Eg: “helm create helloworld”
- This will create a folder structure and will have the files by default as shown below:
- One of the advantages of using helm is that it creates template of code for us, we don’t have to worry about creating them manually and we can use these template and replace it with our respective values and also, we can re-use our code.
- Under template folder we can add all the files that are required for our application such as service.yaml file, deployment.yaml file etc.
Let us go through what chart.yaml include:
- apiVersion: This indicates the chart API version. Here v2 indicates that this chart is build for helm3, this acts as a differentiator between helm2 chart and helm3 chart.
- appVersion: This field includes the version of your application that’s inside of this chart.
- Version: This field indicates version of your chart.
- name: This field indicates the name of the chart.
- Description: Description of the project.
- Type:?There are 2 type of charts, application and library.
- Dependencies: This field will include the dependencies of the application.
- keyword: Keywords helps us in searching these charts in public repository.
- maintainers: Information about the owner.
- home: We can mention url detail in this field.
This file will have the values like Image parameters, dependencies, configuration. This will always override?the values which are defined in the chart file. By default will get a template of values.yaml file when we run the helm create command and that template would look like as shown below:
- As per our requirement we can modify and change the values. Its not necessary to keep all the parameters that are defined in the default values.yaml file. We can customized it as per our application requirement.
Hope you like this article.