Sunday, November 8, 2026

Helm tool vs Kubectl w.r.to creating clusters and application

 Yes. Before running helm install, a Kubernetes cluster must already exist and be running.

Helm does not create a Kubernetes cluster. It installs applications into an existing cluster.

In your case, Minikube creates the Kubernetes cluster, and Helm deploys your application into it.

1. Correct sequence for your application

  1. Start the Kubernetes cluster

    minikube start -p myapp \
      --driver=docker \
      --container-runtime=containerd

    If the myapp profile already exists but is stopped, Minikube starts the existing cluster. Otherwise, it creates a new cluster.

  2. Select the Kubernetes context

    kubectl config use-context myapp

    Verify that the cluster is ready:

    kubectl get nodes
  3. Install the Helm application

    helm upgrade --install myapp ./helm/myapp \
      --kube-context myapp \
      --namespace myapp \
      --create-namespace \
      -f ./helm/myapp/values-minikube.yaml

    This installs your application into the existing Minikube cluster.

  4. Verify the application

    kubectl get pods -n myapp
    kubectl get svc -n myapp
    kubectl get pvc -n myapp

2. What each tool creates

Tool

Responsibility

minikube start -p myapp

Creates or starts the Kubernetes cluster and its nodes

kubectl

Inspects and manages Kubernetes resources

helm install

Installs your application resources into the cluster

helm uninstall

Removes Helm-managed application resources

minikube stop

Stops the cluster without deleting it

minikube delete

Deletes the entire Minikube cluster

3. What if the cluster already exists?

You do not need to recreate it before every Helm installation.

Check:

minikube status -p myapp

If the cluster is already running, directly execute your Helm installation command.

If the cluster is stopped, run:

minikube start -p myapp

If you previously ran helm uninstall, but the Minikube cluster is still running, you can directly reinstall using helm install or helm upgrade --install.

One additional point for your setup: Because your Helm charts use local PVs and PVCs, ensure that the required storage directories and PV definitions are available before installing workloads that depend on them. If your PVs are defined separately from the Helm chart, apply those manifests first.

In summary:

Minikube start → Kubernetes cluster ready → Helm install → Application Pods running

Helm manages applications, not the underlying Kubernetes cluster.

No comments:

Post a Comment