I have a container which use a .json
file to load the configuration it needs.
I tried to find a way to load this configuration. from what I see ConfigMap
has the option to load json
, but in my case the container in the pod is expected it as a mounted file. in addition, it requires apiVersion and other parameters, so im not sure its the same case.
what is the best way to move this file to the pod context and use is in the container as a mounted file?
You should create configMap object using the Json file. Load the configMap as volume in the pod. The api version and other metada that you are referring to is relevant for configMap and not for Json configuration file that you are going use in the running container