Delay application startup till sidecar (hashicorp Vault) is up in Kubernetes Pods

11/19/2021

I am looking for a way where we can start the (NodeJs) app server (i.e. delay it) only after vault agent is up. One way I can think, is to check the availability of the agent (by connecting to 8200) in the readiness probe so that the app server declares itself up only when Agent is up.

I am wondering if there is a "Depends On Container/Sidecar" feature in Helm/Yaml or we need to only do it programmatically in the handler of readiness probe.

Without this this the app server may start accepting request even before vault agent is ready in the sidecar container.

-- Neil
hashicorp-vault
health-check
kubernetes
kubernetes-health-check

0 Answers