I'm running a simple Kubernetes deployment descriptor with podman play kube
and some of my services need env vars to be set. In Docker Compose/Swarm I could just place the names of env-vars to the file and they would be picked up from a host OS. Alternatively, I could use .env
file with Docker Compose for this purpose. But none of these seem to work with podman. I know that Kubernetes offers ConfigMaps for this purpose, but it also doesn't seem to be implemented in podman play kube
. So what's the way of propagating OS environment variables to the container in this case, because I don't really want to explicitly hardcode the values in the .yaml
file?
Podman 2.2.0 (released in December 2020) mentions this in the release notes:
The
podman play kube
command now supports Kubernetes configmaps via the--configmap
optionHere is a link to the latest manual page.