Manual init and unseal — loop script (Approach 1)
Test cases(26 of 50)
Complete the OpenBao prerequisites before running these tests. Go to prerequisites
Seal migration — Shamir to Transit auto-unseal
Seal migration — Shamir to AWS KMS auto-unseal
Requires AWS KMS, IAM permissions, and credentials. Independent of transit auto-unseal (UNSEAL-002).
Enable and Use KV v2 Secrets Engine
KV v2 Metadata and Custom Metadata
KV Secret Rotation Pattern with CAS
Configure PKI Engine as Internal CA
Auto-Rotate TLS Certificates with cert-manager
Cross-Sign External CA with OpenBao PKI
Dynamic PostgreSQL Credentials
Dynamic MySQL/MariaDB Credentials
Kubernetes Auth Method
OIDC Authentication with Keycloak/DEX
Raft Cluster Operations
Raft Snapshot and Restore
Full OpenBao Backup Strategy
Disaster Recovery Restore
TLS Certificates for OpenShift Routes via PKI
Dynamic PostgreSQL Credentials for Applications
Multi-Tenant Secret Isolation
Encryption as a Service - Transit Encryption for Application Data
External Secrets Operator with OpenBao
CSI Secrets Store Driver with OpenBao
OpenBao Agent Sidecar Injector
Deploy the OpenBao Agent Injector to automatically inject secrets into pod containers via init and sidecar containers.
Prerequisites checklist
Confirm these before running steps:
- OpenBao deployed and unsealed with secrets and Kubernetes auth
- OpenBao Agent Injector deployed (part of the initial Helm chart deployment)
- Kubernetes auth role configured for target service accounts
1Verify the OpenBao Agent Injector is running
The injector should be already installed using the initial helm chart deployment. This was done as part of TC-OPENBAO-OCP-001.
Injector was enabled with a replica of 2
oc get pods -l app.kubernetes.io/name=openbao-agent-injector -n openbao2Create a policy and role for the application
bao write auth/kubernetes/role/myapp bound_service_account_names=myapp-sa bound_service_account_namespaces=myapp policies=myapp ttl=1h3Copy OpenBao CA into the app namespace
Since we are using TLS we need to trust the certificate
oc create secret generic openbao-ca -n myapp \
--from-literal=ca.crt="$(oc get secret openbao-ca-secret -n openbao -o jsonpath='{.data.ca\.crt}' | base64 -d)" \
--dry-run=client -o yaml | oc apply -f -4Deploy a pod with OpenBao Agent annotations
Apply from the Commands / YAML tab
5Verify the init and sidecar containers are injected
oc get pods -n myapp -o jsonpath='{.items[0].spec.containers[*].name}'oc get pods -n myapp -o jsonpath='{.items[0].spec.initContainers[*].name}'6Verify secrets are rendered in the pod
Get the pods name
oc get pods -n myappoc exec -it <pod-name> -c app -n myapp -- cat /vault/secrets/config.txtSuccess:
config.txt contains the secret7Clean up
oc delete deployment myapp -n myappSealed Secrets Migration to OpenBao