Last active
January 18, 2022 00:07
-
-
Save vfarcic/1de3e0fc64c61ce5b88a83051bafc7bb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Source: https://gist.github.com/1de3e0fc64c61ce5b88a83051bafc7bb | |
######################################## | |
# Bitnami Kubeapps # | |
# Application Dashboard for Kubernetes # | |
# https://youtu.be/DJ_k5fhODi0 # | |
######################################## | |
# Referenced videos: | |
# - K3d - How to run Kubernetes cluster locally using Rancher k3s: https://youtu.be/mCesuGk-Fks | |
# - Lens - Kubernetes IDE and Dashboard: https://youtu.be/q_ooC1xcGCg | |
# - k9s Kubernetes UI - A Terminal-Based Vim-Like Kubernetes Dashboard: https://youtu.be/boaW9odvRCc | |
######### | |
# Setup # | |
######### | |
git clone https://github.com/vfarcic/kubeapps-demo | |
cd kubeapps-demo | |
# Please watch https://youtu.be/mCesuGk-Fks if you are not familiar with k3d | |
# Feel free to use any other Kubernetes platform | |
k3d cluster create --config k3d.yaml | |
# If you are not using k3d, please install Ingress any way that fits your Kubernetes distribution | |
# Replace `127.0.0.1` with the Ingress Service IP if not using kind | |
export INGRESS_HOST=127.0.0.1 | |
####################### | |
# Installing Kubeapps # | |
####################### | |
helm repo add bitnami \ | |
https://charts.bitnami.com/bitnami | |
helm upgrade --install \ | |
kubeapps bitnami/kubeapps \ | |
--namespace kubeapps \ | |
--create-namespace \ | |
--set ingress.enabled=true \ | |
--set ingress.hostname=kubeapps.$INGRESS_HOST.nip.io \ | |
--wait | |
# We should use a "proper" authentication. | |
# This is for demo purposes only | |
kubectl --namespace default \ | |
create serviceaccount kubeapps-operator | |
kubectl create \ | |
clusterrolebinding kubeapps-operator \ | |
--clusterrole cluster-admin \ | |
--serviceaccount default:kubeapps-operator | |
kubectl get secret \ | |
$(kubectl get \ | |
serviceaccount kubeapps-operator \ | |
--output jsonpath='{range .secrets[*]}{.name}{"\n"}{end}' \ | |
| grep kubeapps-operator-token) \ | |
--output jsonpath='{.data.token}' \ | |
--output go-template='{{.data.token | base64decode}}' | |
# Copy it | |
echo http://kubeapps.$INGRESS_HOST.nip.io | |
# Open it in a browser | |
########### | |
# Destroy # | |
########### | |
k3d cluster delete devops-toolkit |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment