Slide 1

Slide 1 text

Dynamic Environments Using #Helm and #Kubernetes

Slide 2

Slide 2 text

cloud advocate_ quem sou eu_ /khaosdoctor @_staticvoid lsantos.dev /khaosdoctor [email protected]

Slide 3

Slide 3 text

obarra.co trainingcenter.io

Slide 4

Slide 4 text

Development teams_

Slide 5

Slide 5 text

Team Code Tests Staging QA

Slide 6

Slide 6 text

The problem_

Slide 7

Slide 7 text

Dev Code Tests Dev Testing... Staging

Slide 8

Slide 8 text

The perfect world_

Slide 9

Slide 9 text

Dev 2 Code Tests Staging 2 Dev 1 Dev 3 Staging 1 Staging 3

Slide 10

Slide 10 text

How to achieve this?

Slide 11

Slide 11 text

No content

Slide 12

Slide 12 text

- Container Orchestrator - Developed by Google in 2000 - Scaling, state and version management - Cluster based - Declarative

Slide 13

Slide 13 text

- Kubernetes package manager - Allows for manifest files to be grouped into Charts - Templating - Easier way to create and tear down environments

Slide 14

Slide 14 text

How do we start_?

Slide 15

Slide 15 text

We create a Helm chart for our application

Slide 16

Slide 16 text

helm create

Slide 17

Slide 17 text

No content

Slide 18

Slide 18 text

Chart.yaml

Slide 19

Slide 19 text

No content

Slide 20

Slide 20 text

helm install

Slide 21

Slide 21 text

The CI_

Slide 22

Slide 22 text

No content

Slide 23

Slide 23 text

No content

Slide 24

Slide 24 text

No content

Slide 25

Slide 25 text

No content

Slide 26

Slide 26 text

No content

Slide 27

Slide 27 text

Demo

Slide 28

Slide 28 text

Design patterns_

Slide 29

Slide 29 text

Design Patterns - Manual testing environments by branch - Automatic testing environment by PR on release branch - Automatic testing environment by a "RC" tag - Automatic testing environment at each new version - Hybrid using manual branching with PRs on release

Slide 30

Slide 30 text

tips_

Slide 31

Slide 31 text

tips_ - Tearing down an environment is equally important as creating one - Do NOT use the production database (yeah… It happened) - Not all features need a testing environment - Make the environment creation and destruction as a manual approach - Do NOT use production passwords anywhere else (yeah… It also happened) - Keep it simple - Don't early-optimise

Slide 32

Slide 32 text

referências_ - helm.sh - kubernetes.io - dev.azure.com/lsantos-projects/helm-dynamic-envs - github.com/khaosdoctor/helm-dynamic-envs - helm.sh/docs/developing_charts/ - helm.sh/docs/chart_template_guide/

Slide 33

Slide 33 text

referências_ - https://aka.ms/aks-workshop-intro - https://aka.ms/helm-intro - https://aka.ms/helm-charts-intro - https://aka.ms/helm-az-cr - https://aka.ms/az-devops-docs - https://aka.ms/az-kubernetes - https://aka.ms/az-aks-tutorial

Slide 34

Slide 34 text

/khaosdoctor @_staticvoid lsantos.dev /khaosdoctor obrigado_