mirror of
https://github.com/rancher/rancher-docs.git
synced 2026-08-20 08:52:32 +00:00
Merge pull request #376 from MBishop17/configmap
Added Config Maps to documentation
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
---
|
||||
title: Adding ConfigMaps
|
||||
weight:
|
||||
draft: true
|
||||
---
|
||||
|
||||
ConfigMaps store general configuration information for an application, such as configuration files, command-line arguments, environment variables, etc. ConfigMaps accept key value pairs in common string formats, like config files or JSON blobs. Add ConfigMaps to your Rancher workspaces so that you can add them to your workloads later. For more information on ConfigMaps, see the official [Kubernetes Documentation: Using ConfigMap](https://kubernetes-v1-4.github.io/docs/user-guide/configmap/).
|
||||
|
||||
>**Note:** ConfigMaps can only be applied to namespaces and not projects.
|
||||
|
||||
1. From the **Global** view, select the project containing the namespace that you want to add a ConfigMap to.
|
||||
|
||||
1. From the main menu, select **Resources > Config Maps**. Click **Add Config Map**.
|
||||
|
||||
1. Enter a **Name** for the Config Map.
|
||||
|
||||
>**Note:** Kubernetes classifies ConfigMaps as [secrets](https://kubernetes.io/docs/concepts/configuration/secret/), and no two secrets in a project or namespace can have duplicate names. Therefore, to prevent conflicts, your ConfigMaps must have a unique name among the other certificates, ConfigMaps, registries, and secrets within your workspace.
|
||||
|
||||
1. Select the **Namespace** you want to add Config Map to. You can also add a new namespace on the fly by clicking **Add to a new namespace**.
|
||||
|
||||
1. From **Config Map Values**, click **Add Config Map Value** to add a key value pair to your ConfigMap. Add as many values as you need.
|
||||
|
||||
|
||||
>**Note:** Don't use ConfigMaps to store sensitive data [use a secret](../add-a-secret).
|
||||
>
|
||||
>**Tip:** You can add multiple key value pairs to the ConfigMap by copying and pasting.
|
||||
>
|
||||
> 
|
||||
|
||||
|
||||
**Result:** Your ConfigMap is added to the namespace. You can view it in the Rancher UI from the **Resources > Config Maps** view.
|
||||
|
||||
## What's Next?
|
||||
|
||||
Now that you have a ConfigMap added to a namespace, you can add it to a workload that you deploy from the namespace of origin. You can use the ConfigMap to specify information for you application to consume, such as:
|
||||
|
||||
- Application environment variables.
|
||||
- Specifying parameters for a Volume mounted to the workload.
|
||||
|
||||
For more information on adding ConfigMaps to a workload, see [Deploying Workloads](../../workloads/deploy-workloads).
|
||||
@@ -1,6 +0,0 @@
|
||||
---
|
||||
title: Adding Configuration Maps
|
||||
weight:
|
||||
draft: true
|
||||
---
|
||||
Coming Soon
|
||||
@@ -22,9 +22,15 @@ Deploy a workload to run an application in one or more containers.
|
||||
1. Configure the remaining options:
|
||||
|
||||
- **Environment Variables**
|
||||
|
||||
Use this section to either specify environment variables for your workload to consume on the fly, or to pull them from another source, such as a secret or [ConfigMap](../../projects/add-configmaps).
|
||||
|
||||
- **Node Scheduling**
|
||||
- **Health Check**
|
||||
- **Volumes**
|
||||
- **Volumes**
|
||||
|
||||
Use this section to add storage for your workload. You can manually specify the volume that you want to add, use a persistent volume claim to dynamically create a volume for the workload, or read data for a volume to use from a file such as a [ConfigMap](../../projects/add-configmaps).
|
||||
|
||||
- **Scaling/Upgrade Policy**
|
||||
|
||||
1. Click **Show Advanced Options** and configure:
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 721 KiB |
Reference in New Issue
Block a user