SlideShare a Scribd company logo
1 of 22
Kubernetes CI/CD with Helm:
Checking in your deployment configuration as code
Adnan Abdulhussein - @prydonius
Software Engineer, Bitnami
Agenda
Benefits of configuration/infrastructure as code
Managing Kubernetes deployments
Introduction to Helm
Demo CI/CD pipeline with Helm
Configuration and Infrastructure
as Code
Host Management CI/CD InfrastructurePackaging
Configuration and Infrastructure
as Code
Why?
Version Control
Consistent
Reproducible
Rollbacks
Auditing
Tools
Source Code
Management
CI/CD Platform Deployment Tool
Orchestration
Platform
Kubernetes Resource Definitions
MariaDB
Service
resource
Database tier
Secret
resource
Deployment
resource
Application
Service
resource
Backend tier
Config Map
resource
Deployment
resource
Nginx
Service
resource
Frontend tier
Deployment
resource
Example: Kubernetes Resource
apiVersion: v1
kind: Deployment
metadata:
name: my-app
spec:
replicas: 3
template:
metadata:
labels:
app: my-app
spec:
containers:
- name: my-app
image: prydonius/node-todo:v1.0.0
ports:
- containerPort: 8080
livenessProbe:
httpGet:
path: /
port: 8080
initialDelaySeconds: 120
timeoutSeconds: 5
Example: Deploying to Kubernetes
$ kubectl apply -f ./mariadb-secret.yaml
secret "mariadb" configured
$ kubectl apply -f ./mariadb-deployment.yaml
deployment "mariadb" configured
$ kubectl apply -f ./mariadb-service.yaml
service "mariadb" configured
$ kubectl apply -f ./application-configmap.yaml
configmap "application" configured
$ kubectl apply -f ./application-deployment.yaml
deployment "application" configured
$ kubectl apply -f ./application-service.yaml
service "application" configured
$ kubectl apply -f ./nginx-deployment.yaml
deployment "nginx" configured
$ kubectl apply -f ./nginx-service.yaml
service "nginx" configured
Managing raw
manifests can be
difficult
No template parameterization
No application lifecycle hooks
No history of releases
Tool for managing
resources as a
single unit
Reuse resources
Logically group app resources
Manage app lifecycles
Charts
(packages)
Application definitions
Consist of
Metadata (Chart.yaml)
Kubernetes templates
Configuration file (values.yaml)
Documentation
Can depend on other charts
Navigating a Chart
MariaDB
Service
resource
Database tier
Secret
resource
Deployment
resource
Application
Service
resource
Backend tier
Config Map
resource
Deployment
resource
Nginx
Service
resource
Frontend tier
Deployment
resourceDocumentation
Metadata
Config File
helm install my-app
myapp
├── Chart.yaml
├── README.md
├── charts
│ └── mariadb-0.5.8.tgz
├── templates
│ ├── deployment.yaml
│ └── ...
└── values.yaml
Navigating a Chart
Public charts repository
CLI tool
Takes a local Chart path
Set parameters used in Chart templates
Release state stored in cluster
How the Helm can I setup CD?
Generic CI/CD pipeline
Code/config change
Build
Test
Publish artifacts
Staging/QA Deployment
Production Deployment
Manual verification
Demo: CI/CD Pipeline
Code/config change
Build
Test
Push Docker image
Staging/QA Deployment
Production Deployment
Manual verification
Demo: Todo List App
Application Code
Dockerfile
Jenkinsfile
Helm Chart
prydonius/node-todo
Amazing Todo App
● Express.js server
● Angular frontend
● MongoDB database
Demo
Helm + Jenkins vs. Spinnaker
Helm and Jenkins
+ config as code, single source of truth
+ multi-branch support (including pull requests)
+ rich source of plugins
+ single platform for CI and CD
Spinnaker
- more deployment strategies
Helm Community
Over 100 contributors
1.5 years old
Slack channel: Kubernetes/#Helm
Public dev meetings: Thursdays @ 9:30 pacific
Weekly updates & demos at SIG-Apps meetings: Mondays @ 9am pacific
Join
us!
Thank youTime for questions and (hopefully) answers...

More Related Content

What's hot

An Introduction to Kubernetes
An Introduction to KubernetesAn Introduction to Kubernetes
An Introduction to KubernetesImesh Gunaratne
 
Helm – The package manager for Kubernetes
Helm – The package manager for KubernetesHelm – The package manager for Kubernetes
Helm – The package manager for KubernetesFabianRosenthal1
 
Docker and kubernetes_introduction
Docker and kubernetes_introductionDocker and kubernetes_introduction
Docker and kubernetes_introductionJason Hu
 
Hands-On Introduction to Kubernetes at LISA17
Hands-On Introduction to Kubernetes at LISA17Hands-On Introduction to Kubernetes at LISA17
Hands-On Introduction to Kubernetes at LISA17Ryan Jarvinen
 
Kubernetes a comprehensive overview
Kubernetes   a comprehensive overviewKubernetes   a comprehensive overview
Kubernetes a comprehensive overviewGabriel Carro
 
Containers Anywhere with OpenShift by Red Hat
Containers Anywhere with OpenShift by Red HatContainers Anywhere with OpenShift by Red Hat
Containers Anywhere with OpenShift by Red HatAmazon Web Services
 
Kubernetes Architecture and Introduction
Kubernetes Architecture and IntroductionKubernetes Architecture and Introduction
Kubernetes Architecture and IntroductionStefan Schimanski
 
OpenShift 4 installation
OpenShift 4 installationOpenShift 4 installation
OpenShift 4 installationRobert Bohne
 
Kubernetes - introduction
Kubernetes - introductionKubernetes - introduction
Kubernetes - introductionSparkbit
 
K8s in 3h - Kubernetes Fundamentals Training
K8s in 3h - Kubernetes Fundamentals TrainingK8s in 3h - Kubernetes Fundamentals Training
K8s in 3h - Kubernetes Fundamentals TrainingPiotr Perzyna
 
Kubernetes: A Short Introduction (2019)
Kubernetes: A Short Introduction (2019)Kubernetes: A Short Introduction (2019)
Kubernetes: A Short Introduction (2019)Megan O'Keefe
 
Introduction to Kubernetes Workshop
Introduction to Kubernetes WorkshopIntroduction to Kubernetes Workshop
Introduction to Kubernetes WorkshopBob Killen
 
Kubernetes Introduction
Kubernetes IntroductionKubernetes Introduction
Kubernetes IntroductionEric Gustafson
 
OpenShift Overview
OpenShift OverviewOpenShift Overview
OpenShift Overviewroundman
 
A brief study on Kubernetes and its components
A brief study on Kubernetes and its componentsA brief study on Kubernetes and its components
A brief study on Kubernetes and its componentsRamit Surana
 

What's hot (20)

An Introduction to Kubernetes
An Introduction to KubernetesAn Introduction to Kubernetes
An Introduction to Kubernetes
 
Helm 3
Helm 3Helm 3
Helm 3
 
Helm – The package manager for Kubernetes
Helm – The package manager for KubernetesHelm – The package manager for Kubernetes
Helm – The package manager for Kubernetes
 
Docker and kubernetes_introduction
Docker and kubernetes_introductionDocker and kubernetes_introduction
Docker and kubernetes_introduction
 
Hands-On Introduction to Kubernetes at LISA17
Hands-On Introduction to Kubernetes at LISA17Hands-On Introduction to Kubernetes at LISA17
Hands-On Introduction to Kubernetes at LISA17
 
Kubernetes a comprehensive overview
Kubernetes   a comprehensive overviewKubernetes   a comprehensive overview
Kubernetes a comprehensive overview
 
Helm.pptx
Helm.pptxHelm.pptx
Helm.pptx
 
Introduction to kubernetes
Introduction to kubernetesIntroduction to kubernetes
Introduction to kubernetes
 
Containers Anywhere with OpenShift by Red Hat
Containers Anywhere with OpenShift by Red HatContainers Anywhere with OpenShift by Red Hat
Containers Anywhere with OpenShift by Red Hat
 
Kubernetes 101
Kubernetes 101Kubernetes 101
Kubernetes 101
 
Kubernetes Architecture and Introduction
Kubernetes Architecture and IntroductionKubernetes Architecture and Introduction
Kubernetes Architecture and Introduction
 
OpenShift 4 installation
OpenShift 4 installationOpenShift 4 installation
OpenShift 4 installation
 
Kubernetes - introduction
Kubernetes - introductionKubernetes - introduction
Kubernetes - introduction
 
K8s in 3h - Kubernetes Fundamentals Training
K8s in 3h - Kubernetes Fundamentals TrainingK8s in 3h - Kubernetes Fundamentals Training
K8s in 3h - Kubernetes Fundamentals Training
 
Hands-on Helm
Hands-on Helm Hands-on Helm
Hands-on Helm
 
Kubernetes: A Short Introduction (2019)
Kubernetes: A Short Introduction (2019)Kubernetes: A Short Introduction (2019)
Kubernetes: A Short Introduction (2019)
 
Introduction to Kubernetes Workshop
Introduction to Kubernetes WorkshopIntroduction to Kubernetes Workshop
Introduction to Kubernetes Workshop
 
Kubernetes Introduction
Kubernetes IntroductionKubernetes Introduction
Kubernetes Introduction
 
OpenShift Overview
OpenShift OverviewOpenShift Overview
OpenShift Overview
 
A brief study on Kubernetes and its components
A brief study on Kubernetes and its componentsA brief study on Kubernetes and its components
A brief study on Kubernetes and its components
 

Similar to Kubernetes CI/CD with Helm

Continuous Delivery to Kubernetes Using Helm
Continuous Delivery to Kubernetes Using HelmContinuous Delivery to Kubernetes Using Helm
Continuous Delivery to Kubernetes Using HelmAdnan Abdulhussein
 
Deploy your favorite apps on Kubernetes
Deploy your favorite apps on KubernetesDeploy your favorite apps on Kubernetes
Deploy your favorite apps on KubernetesAdnan Abdulhussein
 
Can i service this from my raspberry pi
Can i service this from my raspberry piCan i service this from my raspberry pi
Can i service this from my raspberry piThoughtworks
 
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)QAware GmbH
 
20171122 aws usergrp_coretech-spn-cicd-aws-v01
20171122 aws usergrp_coretech-spn-cicd-aws-v0120171122 aws usergrp_coretech-spn-cicd-aws-v01
20171122 aws usergrp_coretech-spn-cicd-aws-v01Scott Miao
 
Kubernetes - training micro-dragons without getting burnt
Kubernetes -  training micro-dragons without getting burntKubernetes -  training micro-dragons without getting burnt
Kubernetes - training micro-dragons without getting burntAmir Moghimi
 
Deploying windows containers with kubernetes
Deploying windows containers with kubernetesDeploying windows containers with kubernetes
Deploying windows containers with kubernetesBen Hall
 
Application Lifecycle Management in a Serverless World
Application Lifecycle Management in a Serverless WorldApplication Lifecycle Management in a Serverless World
Application Lifecycle Management in a Serverless WorldAmazon Web Services
 
betterCode Workshop: Effizientes DevOps-Tooling mit Go
betterCode Workshop:  Effizientes DevOps-Tooling mit GobetterCode Workshop:  Effizientes DevOps-Tooling mit Go
betterCode Workshop: Effizientes DevOps-Tooling mit GoQAware GmbH
 
Scaffolding for Serverless: lightning talk for AWS Arlington Meetup
Scaffolding for Serverless: lightning talk for AWS Arlington MeetupScaffolding for Serverless: lightning talk for AWS Arlington Meetup
Scaffolding for Serverless: lightning talk for AWS Arlington MeetupChris Shenton
 
Running the-next-generation-of-cloud-native-applications-using-open-applicati...
Running the-next-generation-of-cloud-native-applications-using-open-applicati...Running the-next-generation-of-cloud-native-applications-using-open-applicati...
Running the-next-generation-of-cloud-native-applications-using-open-applicati...NaveedAhmad239
 
Cloud-native Java EE-volution
Cloud-native Java EE-volutionCloud-native Java EE-volution
Cloud-native Java EE-volutionQAware GmbH
 
.NET Cloud-Native Bootcamp
.NET Cloud-Native Bootcamp.NET Cloud-Native Bootcamp
.NET Cloud-Native BootcampVMware Tanzu
 
GE Predix 新手入门 赵锴 物联网_IoT
GE Predix 新手入门 赵锴 物联网_IoTGE Predix 新手入门 赵锴 物联网_IoT
GE Predix 新手入门 赵锴 物联网_IoTKai Zhao
 
Application Model for Cloud Deployment
Application Model for Cloud DeploymentApplication Model for Cloud Deployment
Application Model for Cloud DeploymentJim Kaskade
 
Orchestration with Kubernetes
Orchestration with KubernetesOrchestration with Kubernetes
Orchestration with KubernetesKunal Kerkar
 
Kubernetes VS. App Service: When the orchestrator challenges the platform
Kubernetes VS. App Service: When the orchestrator challenges the platformKubernetes VS. App Service: When the orchestrator challenges the platform
Kubernetes VS. App Service: When the orchestrator challenges the platformLorenzo Barbieri
 
OpenShift Meetup - Tokyo - Service Mesh and Serverless Overview
OpenShift Meetup - Tokyo - Service Mesh and Serverless OverviewOpenShift Meetup - Tokyo - Service Mesh and Serverless Overview
OpenShift Meetup - Tokyo - Service Mesh and Serverless OverviewMaría Angélica Bracho
 
Developing Serverless Applications on Kubernetes with Knative
Developing Serverless Applications on Kubernetes with KnativeDeveloping Serverless Applications on Kubernetes with Knative
Developing Serverless Applications on Kubernetes with KnativeVMware Tanzu
 

Similar to Kubernetes CI/CD with Helm (20)

Continuous Delivery to Kubernetes Using Helm
Continuous Delivery to Kubernetes Using HelmContinuous Delivery to Kubernetes Using Helm
Continuous Delivery to Kubernetes Using Helm
 
Deploy your favorite apps on Kubernetes
Deploy your favorite apps on KubernetesDeploy your favorite apps on Kubernetes
Deploy your favorite apps on Kubernetes
 
Can i service this from my raspberry pi
Can i service this from my raspberry piCan i service this from my raspberry pi
Can i service this from my raspberry pi
 
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
 
20171122 aws usergrp_coretech-spn-cicd-aws-v01
20171122 aws usergrp_coretech-spn-cicd-aws-v0120171122 aws usergrp_coretech-spn-cicd-aws-v01
20171122 aws usergrp_coretech-spn-cicd-aws-v01
 
Kubernetes - training micro-dragons without getting burnt
Kubernetes -  training micro-dragons without getting burntKubernetes -  training micro-dragons without getting burnt
Kubernetes - training micro-dragons without getting burnt
 
Deep Dive on Serverless Stack
Deep Dive on Serverless StackDeep Dive on Serverless Stack
Deep Dive on Serverless Stack
 
Deploying windows containers with kubernetes
Deploying windows containers with kubernetesDeploying windows containers with kubernetes
Deploying windows containers with kubernetes
 
Application Lifecycle Management in a Serverless World
Application Lifecycle Management in a Serverless WorldApplication Lifecycle Management in a Serverless World
Application Lifecycle Management in a Serverless World
 
betterCode Workshop: Effizientes DevOps-Tooling mit Go
betterCode Workshop:  Effizientes DevOps-Tooling mit GobetterCode Workshop:  Effizientes DevOps-Tooling mit Go
betterCode Workshop: Effizientes DevOps-Tooling mit Go
 
Scaffolding for Serverless: lightning talk for AWS Arlington Meetup
Scaffolding for Serverless: lightning talk for AWS Arlington MeetupScaffolding for Serverless: lightning talk for AWS Arlington Meetup
Scaffolding for Serverless: lightning talk for AWS Arlington Meetup
 
Running the-next-generation-of-cloud-native-applications-using-open-applicati...
Running the-next-generation-of-cloud-native-applications-using-open-applicati...Running the-next-generation-of-cloud-native-applications-using-open-applicati...
Running the-next-generation-of-cloud-native-applications-using-open-applicati...
 
Cloud-native Java EE-volution
Cloud-native Java EE-volutionCloud-native Java EE-volution
Cloud-native Java EE-volution
 
.NET Cloud-Native Bootcamp
.NET Cloud-Native Bootcamp.NET Cloud-Native Bootcamp
.NET Cloud-Native Bootcamp
 
GE Predix 新手入门 赵锴 物联网_IoT
GE Predix 新手入门 赵锴 物联网_IoTGE Predix 新手入门 赵锴 物联网_IoT
GE Predix 新手入门 赵锴 物联网_IoT
 
Application Model for Cloud Deployment
Application Model for Cloud DeploymentApplication Model for Cloud Deployment
Application Model for Cloud Deployment
 
Orchestration with Kubernetes
Orchestration with KubernetesOrchestration with Kubernetes
Orchestration with Kubernetes
 
Kubernetes VS. App Service: When the orchestrator challenges the platform
Kubernetes VS. App Service: When the orchestrator challenges the platformKubernetes VS. App Service: When the orchestrator challenges the platform
Kubernetes VS. App Service: When the orchestrator challenges the platform
 
OpenShift Meetup - Tokyo - Service Mesh and Serverless Overview
OpenShift Meetup - Tokyo - Service Mesh and Serverless OverviewOpenShift Meetup - Tokyo - Service Mesh and Serverless Overview
OpenShift Meetup - Tokyo - Service Mesh and Serverless Overview
 
Developing Serverless Applications on Kubernetes with Knative
Developing Serverless Applications on Kubernetes with KnativeDeveloping Serverless Applications on Kubernetes with Knative
Developing Serverless Applications on Kubernetes with Knative
 

Recently uploaded

Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024StefanoLambiase
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaHanief Utama
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Hr365.us smith
 
Machine Learning Software Engineering Patterns and Their Engineering
Machine Learning Software Engineering Patterns and Their EngineeringMachine Learning Software Engineering Patterns and Their Engineering
Machine Learning Software Engineering Patterns and Their EngineeringHironori Washizaki
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmSujith Sukumaran
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Mater
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Natan Silnitsky
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationBradBedford3
 
Sending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdfSending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdf31events.com
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEEVICTOR MAESTRE RAMIREZ
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfFerryKemperman
 
A healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfA healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfMarharyta Nedzelska
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsSafe Software
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptrcbcrtm
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanyChristoph Pohl
 
Comparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdfComparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdfDrew Moseley
 
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...OnePlan Solutions
 

Recently uploaded (20)

Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief Utama
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)
 
Machine Learning Software Engineering Patterns and Their Engineering
Machine Learning Software Engineering Patterns and Their EngineeringMachine Learning Software Engineering Patterns and Their Engineering
Machine Learning Software Engineering Patterns and Their Engineering
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalm
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
 
2.pdf Ejercicios de programación competitiva
2.pdf Ejercicios de programación competitiva2.pdf Ejercicios de programación competitiva
2.pdf Ejercicios de programación competitiva
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion Application
 
Odoo Development Company in India | Devintelle Consulting Service
Odoo Development Company in India | Devintelle Consulting ServiceOdoo Development Company in India | Devintelle Consulting Service
Odoo Development Company in India | Devintelle Consulting Service
 
Sending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdfSending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdf
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEE
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdf
 
A healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfA healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdf
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data Streams
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.ppt
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
 
Comparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdfComparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdf
 
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
 

Kubernetes CI/CD with Helm

  • 1. Kubernetes CI/CD with Helm: Checking in your deployment configuration as code Adnan Abdulhussein - @prydonius Software Engineer, Bitnami
  • 2. Agenda Benefits of configuration/infrastructure as code Managing Kubernetes deployments Introduction to Helm Demo CI/CD pipeline with Helm
  • 3. Configuration and Infrastructure as Code Host Management CI/CD InfrastructurePackaging
  • 4. Configuration and Infrastructure as Code Why? Version Control Consistent Reproducible Rollbacks Auditing
  • 5. Tools Source Code Management CI/CD Platform Deployment Tool Orchestration Platform
  • 6. Kubernetes Resource Definitions MariaDB Service resource Database tier Secret resource Deployment resource Application Service resource Backend tier Config Map resource Deployment resource Nginx Service resource Frontend tier Deployment resource
  • 7. Example: Kubernetes Resource apiVersion: v1 kind: Deployment metadata: name: my-app spec: replicas: 3 template: metadata: labels: app: my-app spec: containers: - name: my-app image: prydonius/node-todo:v1.0.0 ports: - containerPort: 8080 livenessProbe: httpGet: path: / port: 8080 initialDelaySeconds: 120 timeoutSeconds: 5
  • 8. Example: Deploying to Kubernetes $ kubectl apply -f ./mariadb-secret.yaml secret "mariadb" configured $ kubectl apply -f ./mariadb-deployment.yaml deployment "mariadb" configured $ kubectl apply -f ./mariadb-service.yaml service "mariadb" configured $ kubectl apply -f ./application-configmap.yaml configmap "application" configured $ kubectl apply -f ./application-deployment.yaml deployment "application" configured $ kubectl apply -f ./application-service.yaml service "application" configured $ kubectl apply -f ./nginx-deployment.yaml deployment "nginx" configured $ kubectl apply -f ./nginx-service.yaml service "nginx" configured
  • 9. Managing raw manifests can be difficult No template parameterization No application lifecycle hooks No history of releases
  • 10. Tool for managing resources as a single unit Reuse resources Logically group app resources Manage app lifecycles
  • 11. Charts (packages) Application definitions Consist of Metadata (Chart.yaml) Kubernetes templates Configuration file (values.yaml) Documentation Can depend on other charts
  • 12. Navigating a Chart MariaDB Service resource Database tier Secret resource Deployment resource Application Service resource Backend tier Config Map resource Deployment resource Nginx Service resource Frontend tier Deployment resourceDocumentation Metadata Config File helm install my-app
  • 13. myapp ├── Chart.yaml ├── README.md ├── charts │ └── mariadb-0.5.8.tgz ├── templates │ ├── deployment.yaml │ └── ... └── values.yaml Navigating a Chart
  • 15. CLI tool Takes a local Chart path Set parameters used in Chart templates Release state stored in cluster How the Helm can I setup CD?
  • 16. Generic CI/CD pipeline Code/config change Build Test Publish artifacts Staging/QA Deployment Production Deployment Manual verification
  • 17. Demo: CI/CD Pipeline Code/config change Build Test Push Docker image Staging/QA Deployment Production Deployment Manual verification
  • 18. Demo: Todo List App Application Code Dockerfile Jenkinsfile Helm Chart prydonius/node-todo Amazing Todo App ● Express.js server ● Angular frontend ● MongoDB database
  • 19. Demo
  • 20. Helm + Jenkins vs. Spinnaker Helm and Jenkins + config as code, single source of truth + multi-branch support (including pull requests) + rich source of plugins + single platform for CI and CD Spinnaker - more deployment strategies
  • 21. Helm Community Over 100 contributors 1.5 years old Slack channel: Kubernetes/#Helm Public dev meetings: Thursdays @ 9:30 pacific Weekly updates & demos at SIG-Apps meetings: Mondays @ 9am pacific Join us!
  • 22. Thank youTime for questions and (hopefully) answers...

Editor's Notes

  1. Tools that define configuration or infrastructure as code have existed for a long time, such as Chef and Puppet More recently we've seen this extend to CI pipelines, packaging with Dockerfiles, Packer config, and Infrastructure on clouds with Terraform and AWS CloudFormation, and more recently with Kubernetes and Helm
  2. Single source of truth for all configuration Gives you consistency across your deployments and tools Declarative definitions allow for reproducibility Version control comes with goodies
  3. In this talk, we'll take a look at how to build a whole CI/CD pipeline out of these tools
  4. In Kubernetes, you would define and create multiple resources for each of these tiers Deployment resource - describes what containers to run in the service, how to scale them, healthchecks, resources Service resource - enables service discovery and loadbalancing for your deployments Secret/ConfigMap resource - your application may take in a password or API token that needs to be kept secret Each resource is a declarative definition usually written in YAML or JSON
  5. When you want to go and upgrade your templates to release a new version of your application, you need to manually edit these files to change the tag of the docker image or if you want to change configuration in the configmap this is painful and hard to automate after making changes, it's difficult to rollback to a previous state because history is not tracked for every resource if your application needs to run a database migration during an upgrade you need to build tooling to manage this during your release process
  6. Helm allows you to reduce boilerplate and reuse resources in intelligent ways e.g. provides a public repository to take common components from Bundling different resources together and reordering into dependencies makes resources easier to manage and update Helm allows you to hook into your deployments and run database migrations at certain points in the deployment process
  7. Packages in Helm are called Charts They consist of metadata, templates, config files and docs They can depend on other charts
  8. Mostly the same as before, but Helm packages this all as a bundle Also containers metadata, docs, config file for exposing configuration for your app during install-time
  9. Laid out into two chart repos: Incubator - great place for sharing and developing ideas, and trying out new k8s alpha features Stable - a place for curated, ready-to-run applications
  10. Build - Docker Test - ??? Release artifacts - Image registry Manual verification - Yes no, maybe so? Staging environment Deploy - Production
  11. Build - Docker Test - ??? Release artifacts - Image registry Manual verification - Yes no, maybe so? Staging environment Deploy - Production