Foreword
Read little, type a lot. This book shows how workloads, pipelines and
applications get their secrets from OpenBao without a password ending up
in Git, in an image or in a build log. Everything runs on your laptop: a
kind cluster, OpenBao in dev mode and a small demo application
shop-api that you will meet again in every chapter.
The book is for platform engineers, DevOps and security people who already run OpenBao (or Vault), or have someone run it for them, and now want to connect to it properly. Installation, HA with Raft, unseal, backup and upgrades are covered in the sister book “OpenBao hands-on”. Here, OpenBao is simply there.
The Training Rules
- Type, don’t copy. Run every command yourself once.
- Compare with Expected. After every drill you will find what you should see. If it differs, that is where the real lesson is.
- Pass the checkpoint. Move on only when the check script shows nothing but ✔.
- Solve the challenge on your own. First the hint, then the solution.
- Lab values stay in the lab.
lab-db-pw-123, the root tokenrootand all otherlab-…values are practice data. OpenBao runs in dev mode: unsecured, in memory, empty after every pod restart.
Structure of Each Training Day
| Section | Purpose |
|---|---|
| Briefing | The essentials in a few bullet points |
| Drills | Commands with expected output |
| Checkpoint | Check script: did everything work? |
| Challenge | A task without instructions |
| Enterprise Note | What is different in production |
The Training Plan
| Part | Day | Unit |
|---|---|---|
| Training ground | 0 | kind, OpenBao in dev mode, demo data, check.sh |
| A – Basic patterns | 1 | Reading secrets: KV v2, policies, response wrapping |
| 2 | Machine identity: Kubernetes auth, JWT auth, templating | |
| B – Kubernetes | 3 | External Secrets Operator: basics |
| 4 | External Secrets Operator: advanced | |
| 5 | Agent Injector | |
| 6 | Secrets Store CSI Driver | |
| 7 | Dynamic secrets and certificates in pods | |
| 8 | Straight from the application: Python, Go,
bao agent |
|
| 9 | Rolling out and reloading: which method when | |
| C – CI/CD | 10 | Pipeline identity: JWT/OIDC, AppRole |
| 11 | GitHub Actions | |
| 12 | GitLab CI and Jenkins | |
| 13 | GitOps and infrastructure pipelines | |
| D – Hardening | 14 | Guardrails and anti-patterns |
| 15 | Competition: disaster drills | |
| Appendix | A | Cheat Sheet |
| B | Final Exam |
Part A lays the foundation that all later days need: How do you read a secret, and how does a machine prove who it is? Part B brings secrets into pods, Part C into pipelines. Part D makes sure it stays that way.
Tip: Tested with OpenBao 2.7.1, Helm chart
openbao0.30.3, kind 0.33 (Kubernetes 1.37), kubectl 1.37 and Helm 4.3. If a flag differs:bao <command> -helpand the official docs atopenbao.org/docs.
The Companion Code
All files from this book are publicly available on GitHub: https://github.com/thomaszachmann/openbao-secrets-zum-anfassen. Day 0 shows how to get them.
Let’s go.
Thomas Zachmann, October 2026