Where do I put Kubernetes config?
By default, kubectl looks for a file named config in the $HOME/. kube directory. You can specify other kubeconfig files by setting the KUBECONFIG environment variable or by setting the –kubeconfig flag.
When would you use a ConfigMap?
Use a ConfigMap to keep your application code separate from your configuration. It is an important part of creating a Twelve-Factor Application. This lets you change easily configuration depending on the environment (development, production, testing) and to dynamically change configuration at runtime.
What are Kubernetes namespaces?
Namespaces are Kubernetes objects which partition a single Kubernetes cluster into multiple virtual clusters. Each Kubernetes namespace provides the scope for Kubernetes Names it contains; which means that using the combination of an object name and a Namespace, each object gets an unique identity across the cluster.
What is the main advantage use case of Kubernetes secrets over ConfigMaps?
A Secret can hold more than one key/value pair, so you can create a single Secret to hold both strings. As a bonus, by using kubectl create secret, you can let Kubernetes mess with base64 so that you don’t have to. Note the –from-literal, which sets the key name and the value all in one.
What do containers share inside a pod?
Within a Pod, containers share an IP address and port space, and can find each other via localhost . The containers in a Pod can also communicate with each other using standard inter-process communications like SystemV semaphores or POSIX shared memory.
What is a Kubernetes config map?
A Kubernetes ConfigMap is an API object that allows you to store data as key-value pairs. Kubernetes pods can use ConfigMaps as configuration files, environment variables or command-line arguments. ConfigMaps allow you to decouple environment-specific configurations from containers to make applications portable.
What is a Kubernetes secret?
In short, a “secret” in Kubernetes is a means of storing sensitive information, like an OAuth token or SSH key, so that it’s accessible when necessary to pods in your cluster but protected from unnecessary visibility that could create security risks.
What provide ConfigMaps to pods and deployments?
Understanding ConfigMaps and Pods The ConfigMap API resource stores configuration data as key-value pairs. The data can be consumed in pods or provide the configurations for system components such as controllers.
What is ConfigMap and secret in Kubernetes?
Kubernetes has two types of objects that can inject configuration data into a container when it starts up: Secrets and ConfigMaps. Secrets and ConfigMaps behave similarly in Kubernetes, both in how they are created and because they can be exposed inside a container as mounted files or volumes or environment variables.
How can I separate application code from configuration in Kubernetes?
A good practice when writing applications is to separate application code from configuration. We want to enable application authors to easily employ this pattern within Kubernetes. While the Secrets API allows separating information like credentials and keys from an application, no object existed in the past for ordinary, non-secret configuration.
Which Kubernetes configuration management tool should you use?
Kustomize is one such overlay configuration tool and is built into the native Kubernetes CLI, kubectl. The final school of thought when it comes to application configuration management is a programmatic one.
How does Kubernetes decide which node to place a pod on?
When you specify the resource request for Containers in a Pod, the scheduler uses this information to decide which node to place the Pod on. When you specify a resource limit for a Container, the kubelet enforces those limits so that the running container is not allowed to use more of that resource than the limit you set.
What’s new in Kubernetes configmap?
In Kubernetes 1.2, we’ve added a new API resource called ConfigMap to handle this type of configuration data. The ConfigMap API is simple conceptually. From a data perspective, the ConfigMap type is just a set of key-value pairs.
https://www.youtube.com/watch?v=EQqosMPP2Is