Created
November 8, 2021 12:36
-
-
Save vfarcic/249f8bb8baa8ca03ff5a1a61f3bda200 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
######################################################### | |
# What Is Linkerd Service Mesh? Linkerd Tutorial Part 1 # | |
# https://youtu.be/mDC3KA_6vfg # | |
######################################################### | |
# Referenced videos: | |
# - Service Mesh In Kubernetes Explained: https://youtu.be/cjhb7_uwzDk | |
# - Should We Replace Docker Desktop With Rancher Desktop?: https://youtu.be/bYVfCp9dRTE | |
# - Kustomize - How to Simplify Kubernetes Configuration Management: https://youtu.be/Twtbg6LFnAg | |
# - Helm vs Kustomize - The Fight Between Templating and Patching in Kubernetes: https://youtu.be/ZMFYSm0ldQ0 | |
# - Argo CD - Applying GitOps Principles To Manage Production Environment In Kubernetes: https://youtu.be/vpWQeoaiRM4 | |
# - Flux CD v2 With GitOps Toolkit - Kubernetes Deployment And Sync Mechanism: https://youtu.be/R6OeIgb7lUI | |
######### | |
# Setup # | |
######### | |
gh repo fork vfarcic/linkerd-demo \ | |
--clone | |
cd linkerd-demo | |
# Create a Kubernetes cluster with Ingress | |
# This demo was tested on Rancher Desktop, but it should work with any Kubernetes cluster | |
# Please watch https://youtu.be/bYVfCp9dRTE if you are not familiar with Rancher Desktop | |
# Replace `127.0.0.1` with the Ingress Service IP if not using Rancher Desktop | |
export INGRESS_IP=127.0.0.1 | |
cat kustomize/overlays/production/ingress.yaml \ | |
| sed -e "s@host: .*@host: dot.$INGRESS_IP.nip.io@g" \ | |
| tee kustomize/overlays/production/ingress.yaml | |
kubectl create namespace production | |
############################# | |
# Install and setup Linkerd # | |
############################# | |
curl -sL https://run.Linkerd.io/install \ | |
| sh | |
linkerd check --pre | |
linkerd install | |
linkerd install \ | |
| kubectl apply --filename - | |
linkerd check | |
linkerd viz install \ | |
| kubectl apply --filename - | |
linkerd jaeger install \ | |
| kubectl apply --filename - | |
Linkerd check | |
########################### | |
# Linkerd Proxy Injection # | |
########################### | |
cat kustomize/base/deployment.yaml | |
cat kustomize/overlays/production/ingress.yaml | |
# Watch https://youtu.be/Twtbg6LFnAg if you are not familiar with Kustomize | |
kubectl apply \ | |
--kustomize kustomize/overlays/production | |
# It could be `linkerd inject -` instead; a bad idea | |
kubectl --namespace production get pods | |
echo http://dot.$INGRESS_IP.nip.io | |
# Open it in a browser | |
############################## | |
# Observability With Linkerd # | |
############################## | |
# Install the latest release of the Ddosify CLI from https://github.com/ddosify/ddosify/releases | |
ddosify -t "http://dot.$INGRESS_IP.nip.io" | |
linkerd --namespace production \ | |
viz stat deploy/devops-toolkit | |
linkerd --namespace production \ | |
viz top deploy/devops-toolkit | |
linkerd viz dashboard & | |
ddosify -config ddosify.json |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment