Questions tagged [configmap]

ConfigMaps allow you to decouple configuration artifacts from image content to keep containerized applications portable.

ConfigMaps bind configuration files, command-line arguments, environment variables, port numbers, and other configuration artifacts to your Pods' containers and system components at runtime. ConfigMaps allow you to separate your configurations from your Pods and components, which helps keep your workloads portable, makes their configurations easier to change and manage, and prevents hardcoding configuration data to Pod specifications.

ConfigMaps are useful for storing and sharing non-sensitive, unencrypted configuration information. To use sensitive information in your clusters, you must use Secrets.

Documentations

503 questions
7
votes
1 answer

embeding conf files into helm chart

Im new at helm. Im building a splunk helm chart with numerous conf files. I currently use something like this in a configmap .. apiVersion: v1 kind: ConfigMap metadata: name: splunk-master-configmap data: indexes.conf: | # global settings …
Nick Gleed
  • 105
  • 1
  • 1
  • 6
6
votes
2 answers

kubernetes config map data value externalisation

I'm installing fluent-bit in our k8s cluster. I have the helm chart for it on our repo, and argo is doing the deployment. Among the resources in the helm chart is a config-map with data value as below: apiVersion: v1 kind: ConfigMap metadata: …
lorraine batol
  • 6,001
  • 16
  • 55
  • 114
6
votes
3 answers

How to expose traefik v2 dashboard in k3d/k3s via configuration?

*Cross-posted to k3d github discussions, to a thread in Rancher forums, and to traefik's community discussion board Tutorials from 2020 refer to editing the traefik configmap. Where did it go? The traefik installation instructions refer to a couple…
Eric Swanson
  • 820
  • 1
  • 9
  • 19
6
votes
1 answer

Kustomize - Merge multiple configMapGenerators

So I'm dealing with a structure like this: . ├── 1 │   ├── env-vars │   └── kustomization.yaml ├── 2 │   ├── env-vars │   └── kustomization.yaml ├── env-vars ├── kustomization.yaml └── shared ├── env-vars └── kustomization.yaml while…
Mahyar
  • 1,011
  • 2
  • 17
  • 37
6
votes
1 answer

Duplicated env variable names in pod definition, what is the precedence rule to determine the final value?

Using Kubernetes 1.19.3, I initialize env variable values using 3 different ways: env field with explicit key/value in the pod definition envFrom using configMapRef and secretRef When a key name is duplicated, as shown in the example below,…
Polymerase
  • 6,311
  • 11
  • 47
  • 65
6
votes
1 answer

Kubectl - How to Read Ingress Hosts from Config Variables?

I have a ConfigMap with a variable for my domain: apiVersion: v1 kind: ConfigMap metadata: name: config data: MY_DOMAIN: mydomain.com and my goal is to use the MY_DOMAIN variable inside my Ingress config apiVersion: extensions/v1beta1 kind:…
6
votes
4 answers

Cannot read configmap with name: [xx] in namespace ['default'] Ignoring

New to k8s. Trying to read values from profile based config map. My configmap exists in default namespace. But, spring boot is not pickingup the values. Config map looks like: apiVersion: v1 kind: ConfigMap metadata: name:…
NANDAKUMAR THANGAVELU
  • 611
  • 3
  • 15
  • 34
6
votes
2 answers

Hosting jar files on Kubernetes ConfigMap

Is this a good idea to host java jar files on ConfigMap when we want to extend a JVM classpath? Normally the application itself is baked into docker image but extending it(via plugin jar etc.) requires either attaching volume, copying the jar file…
Mesut
  • 916
  • 1
  • 7
  • 17
6
votes
1 answer

How to convert YAML to JSON when saving files into container using Kubernetes Configmap

We are going to write Helm chart and providing configuration file using configmap. For some reasons our app is using JSON format configuration file. Currently we provide configuration file in Helm chart's values.yaml like this. conffiles: …
Lijing Zhang
  • 63
  • 1
  • 5
6
votes
1 answer

What happens if a configMap(/secret) mounted as a volume in a running pod, is deleted on the master?

Let's say I have a pod with a configMap (or secret) volume. ConfigMap (or secret) object is present during the pod's creation, but I delete the configMap(or secret) object on the master, while the pod is running. What is the expected behavior? Is it…
5
votes
1 answer

What does the username field in aws-auth configmap do?

I am trying to understand where do these username field is mapped to in the Kubernetes cluster. This is a sample configmap: apiVersion: v1 data: mapRoles: | - rolearn: arn:aws:iam::111122223333:role/eksctl-my-cluster-nodegroup username:…
Kishor Unnikrishnan
  • 1,928
  • 4
  • 21
  • 33
5
votes
1 answer

Kustomize overlays when using a shared ConfigMap

I have an environment made of pods that address their target environment based on an environment variable called CONF_ENV that could be test, stage or prod. The application running inside the Pod has the same source code across environments, the…
TPPZ
  • 4,447
  • 10
  • 61
  • 106
5
votes
1 answer

helm configmap in values.yaml

I am trying to do the following, so where MYVALUE in host needs to change to include Release Name. Can't figure how to do this, as you can't use env variables like {{ .Release.Name }} directly in to a values.yaml file. I did do a fullnameOverride…
sam
  • 109
  • 2
  • 3
  • 12
5
votes
0 answers

failed to sync configmap cache: timed out

I am creating a helm chart that contains many configmaps (20+) and everytime that I launch it the pod crashes and when I run kubectl describe it is full of warnings such as below: Warning FailedMount 24m kubelet, A-p51 …
AVarf
  • 4,481
  • 9
  • 47
  • 74
5
votes
2 answers

How can we specify custom path to .Files.Get when creating ConfigMap with Helm

I am creating a config map as below kubectl create configmap testconfigmap --from-file=testkey=/var/opt/testfile.txt As I am using helm charts, I would like to create the config map using YAML file instead of running kubectl. I went through…
Sanjay
  • 61
  • 1
  • 2
1 2
3
33 34