Day 5 of 5
⏱ ~60 minutes
Kubernetes in 5 Days — Day 5

Helm: Package Manager for K8s

Install Helm, deploy a chart from a public repo, write your own chart with values, and set up a simple CI pipeline.

What Helm Solves

A real application needs a Deployment, Service, ConfigMap, Ingress, ServiceAccount, and maybe a Secret. That's 6+ YAML files. Helm packages them into a single chart with configurable values. Instead of editing YAML, you set values.

Install Helm and Deploy a Chart
# Install: helm.sh/docs/intro/install
curl https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash

# Add a chart repository
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo update

# Install nginx from bitnami
helm install my-nginx bitnami/nginx

# List installed releases
helm list

# Upgrade
helm upgrade my-nginx bitnami/nginx --set replicaCount=3

# Uninstall
helm uninstall my-nginx
Create Your Own Chart
helm create my-app
# Creates:
# my-app/
#   Chart.yaml     ← chart metadata
#   values.yaml    ← default values
#   templates/     ← Kubernetes YAML with Go templates
#     deployment.yaml
#     service.yaml
#     ingress.yaml
values.yaml
replicaCount: 2

image:
  repository: nginx
  tag: '1.25'
  pullPolicy: IfNotPresent

service:
  type: ClusterIP
  port: 80

ingress:
  enabled: true
  host: myapp.local
Install with custom values
helm install my-release ./my-app \
  --set replicaCount=3 \
  --set image.tag=1.26

# Or use a values file
helm install my-release ./my-app -f production-values.yaml
📝 Day 5 Exercise
Package Your App with Helm
  1. C
  2. r
  3. e
  4. a
  5. t
  6. e
  7. a
  8. H
  9. e
  10. l
  11. m
  12. c
  13. h
  14. a
  15. r
  16. t
  17. f
  18. o
  19. r
  20. y
  21. o
  22. u
  23. r
  24. D
  25. e
  26. p
  27. l
  28. o
  29. y
  30. m
  31. e
  32. n
  33. t
  34. +
  35. S
  36. e
  37. r
  38. v
  39. i
  40. c
  41. e
  42. +
  43. I
  44. n
  45. g
  46. r
  47. e
  48. s
  49. s
  50. f
  51. r
  52. o
  53. m
  54. e
  55. a
  56. r
  57. l
  58. i
  59. e
  60. r
  61. l
  62. e
  63. s
  64. s
  65. o
  66. n
  67. s
  68. .
  69. P
  70. a
  71. r
  72. a
  73. m
  74. e
  75. t
  76. e
  77. r
  78. i
  79. z
  80. e
  81. t
  82. h
  83. e
  84. i
  85. m
  86. a
  87. g
  88. e
  89. t
  90. a
  91. g
  92. a
  93. n
  94. d
  95. r
  96. e
  97. p
  98. l
  99. i
  100. c
  101. a
  102. c
  103. o
  104. u
  105. n
  106. t
  107. i
  108. n
  109. v
  110. a
  111. l
  112. u
  113. e
  114. s
  115. .
  116. y
  117. a
  118. m
  119. l
  120. .
  121. I
  122. n
  123. s
  124. t
  125. a
  126. l
  127. l
  128. i
  129. t
  130. w
  131. i
  132. t
  133. h
  134. c
  135. u
  136. s
  137. t
  138. o
  139. m
  140. v
  141. a
  142. l
  143. u
  144. e
  145. s
  146. .
  147. U
  148. p
  149. g
  150. r
  151. a
  152. d
  153. e
  154. i
  155. t
  156. b
  157. y
  158. c
  159. h
  160. a
  161. n
  162. g
  163. i
  164. n
  165. g
  166. t
  167. h
  168. e
  169. r
  170. e
  171. p
  172. l
  173. i
  174. c
  175. a
  176. c
  177. o
  178. u
  179. n
  180. t
  181. .

Day 5 Summary

  • Helm packages multiple Kubernetes manifests into one installable chart.
  • helm install release-name chart-name. helm upgrade updates. helm rollback reverts.
  • Charts use Go templates. {{ .Values.replicaCount }} renders the value from values.yaml.
  • Public charts (bitnami, etc.) let you install complex software (PostgreSQL, Redis) in one command.
Finished this lesson?