Injecting Configuration from a Single File
In this lesson, we will learn to inject configuration from a single file using the ConfigMap Volume.
Creating a ConfigMap
In its purest, and probably the most common form, a ConfigMap takes a single file. For example, we can create one from the cm/prometheus-conf.yml file.
We created a ConfigMap (cm) called my-config. The data of the map is the content of the cm/prometheus-conf.yml file.
Looking into the Description
Let’s describe it, and see what we’ll get.
The output is as follows.
The important part is located below Data. We can see the key which, in this case, is the name of the file ( ...
Access this course and 1600+ top-rated courses and projects.