You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Any resource we manage using HELM are specific to Kubernetes Namespace
By default, Kubernetes resources deployed to k8s cluster using default namespace, so we don't need to specify namespace name explicitly
In the case if we want to deploy k8s resources to a namespace (other than default), then we need to specify that in helm install command with flag --namespace or -n
In addition, we can also create a namespace during helm install using flags --namespace--create-namespace
Step-02: Install Helm Release by creating Kubernetes Namespace dev
# List Kubernetes Namespaces
kubectl get ns
# Install Helm Release by creating Kubernetes Namespace
helm install dev101 stacksimplify/mychart2 --version "0.1.0" --namespace dev --create-namespace
# List Kubernetes Namespaces
kubectl get ns
Observation: Found the dev namespace created as part of `helm install`# List Helm Release
helm list --> NO RELEASES in default namespace
helm list -n dev
helm list --namespace dev
# Helm Status
helm status dev101 --show-resources -n dev
helm status dev101 --show-resources --namespace dev
# List Kubernetes Pods
kubectl get pods -n dev
kubectl get pods --namespace dev
# List Services
kubectl get svc -n dev
# List Deployments
kubectl get deploy -n dev
# Access Application
http://localhost:31232
Step-03: Run helm upgrade for resources present in dev namespace
# Helm Upgrade
helm upgrade dev101 stacksimplify/mychart2 --version "0.2.0" --namespace dev
or
helm upgrade dev101 stacksimplify/mychart2 --version "0.2.0" -n dev
# List Helm Release
helm list -n dev
helm list --namespace dev
# Helm Status
helm status dev101 --show-resources -n dev
helm status dev101 --show-resources --namespace dev
# Access Application
http://localhost:31232
Step-04: Uninstall Helm Release from dev Namespace
# Uninstall Helm Releas
helm uninstall dev101 --namespace dev
helm uninstall dev101 -n dev
# List Helm Release
helm list -n dev
helm list --namespace dev
# List Kubernetes Namespaces
kubectl get ns
Observation:
1. When uninstalling helm release, it will notdelete the Kubernetes Resource: dev namespace.
2. If we dont need that dev namespace we need to manually delete it from kubernetes using kubectl
# Delete dev namespace
kubectl delete ns dev
# List Kubernetes Namespaces
kubectl get ns