-
-
Save adriancbo/ec48900585e9a0ddb155465ac966e8f3 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
###################################################### | |
# Devtron # | |
# Kubernetes-Native User-Friendly CI, CD, and GitOps # | |
# https://youtu.be/ZKcfZC-zSMM # | |
###################################################### | |
# Referenced videos: | |
# - Argo CD - Applying GitOps Principles To Manage Production Environment In Kubernetes: https://youtu.be/vpWQeoaiRM4 | |
# - Argo Workflows and Pipelines - CI/CD, Machine Learning, and Other Kubernetes Workflows: https://youtu.be/UMaivwrAyTA | |
# - Argo Events - Event-Based Dependency Manager for Kubernetes: https://youtu.be/sUPkGChvD54 | |
# - Argo Rollouts - Canary Deployments Made Easy In Kubernetes: https://youtu.be/84Ky0aPbHvY | |
# - GitHub CLI - How to manage repositories more efficiently: https://youtu.be/BII6ZY2Rnlc | |
######### | |
# Setup # | |
######### | |
# Create a Kubernetes cluster | |
# Watch https://youtu.be/BII6ZY2Rnlc if you are not familiar with GitHub CLI | |
gh repo fork vfarcic/devtron-demo \ | |
--clone | |
cd devtron-demo | |
helm repo add devtron https://helm.devtron.ai | |
helm repo update | |
helm show values devtron/devtron-operator | |
helm upgrade --install \ | |
devtron devtron/devtron-operator \ | |
--namespace devtroncd \ | |
--create-namespace \ | |
--wait | |
kubectl --namespace devtroncd \ | |
get installers installer-devtron \ | |
--output jsonpath='{.status.sync.status}' | |
# Wait until the output is `Applied` | |
################# | |
# What's inside # | |
################# | |
kubectl get namespaces | |
kubectl --namespace devtroncd get pods | |
################# | |
# Devtron setup # | |
################# | |
# If NOT EKS | |
export DEVTRON_IP=$(kubectl --namespace devtroncd \ | |
get service devtron-service \ | |
--output jsonpath="{.status.loadBalancer.ingress[0].ip}") | |
# If EKS | |
export DEVTRON_IP=$(kubectl --namespace devtroncd \ | |
get service devtron-service \ | |
--output jsonpath="{.status.loadBalancer.ingress[0].hostname}") | |
echo "http://$DEVTRON_IP" | |
# Open it in a browser | |
echo $(kubectl --namespace devtroncd \ | |
get secret devtron-secret \ | |
--output jsonpath="{.data.ACD_PASSWORD}" \ | |
| base64 -d) | |
######################### | |
# Deploying Helm charts # | |
######################### | |
kubectl --namespace devtroncd get applications | |
kubectl --namespace devtroncd \ | |
get application --output yaml | |
# Open the address from the `spec.source.repoURL` field. | |
# Delete the chart | |
######################## | |
# Running the pipeline # | |
######################## | |
echo "This is a test" | tee README.md | |
git add . | |
git commit -m "A silly change" | |
git push | |
kubectl --namespace staging get all,ingresses | |
# Install Ingress (e.g., NGINX Ingress) following the instructions for your Kubernetes platform. | |
echo "This is a test 2" | tee README.md | |
git add . | |
git commit -m "Another silly change" | |
git push | |
kubectl --namespace staging get all,ingresses | |
########### | |
# Destroy # | |
########### | |
# Destroy the cluster |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment