This example program demonstrates helm operations for managing helm charts, such as adding helm repo, fetching helm charts and installing a helm chart
Running this example does the following operations:
-
Adds helm chart repo with name
stableand urlhttps://kubernetes-charts.storage.googleapis.com(equivalent tohelm repo add stable https://kubernetes-charts.storage.googleapis.com) -
Fetches latest helm charts from stable helm repo (equivalent to
helm repo update) -
Installs
mysqlhelm chart intomysql-testnamespace with values (equivalent tohelm install -n mysql --namespace mysql-test stable/mysql --set mysqlRootPassword=admin@123,persistence.enabled=false,imagePullPolicy=Always)
- Create namespace
mysql-testkubectl create ns mysql-test - Run the program with
go run main.go