Mount ConfigMaps
Mount Kubernetes ConfigMaps into workspace containers to provide non-sensitive configuration data.
Before you begin
- You have an active
ocsession with your project. See This page is not included, but the link has been rewritten to point to the nearest parent document.Getting started with the CLI.Warning:By default, applying a
ConfigMapwith thecontroller.devfile.io/mount-to-devworkspace: 'true'label restarts all running workspaces in the project. To mount the ConfigMap only at workspace start and prevent automatic restarts, add thecontroller.devfile.io/mount-on-start: 'true'annotation.
Procedure
Results
- For
fileorsubpathmounts, verify the ConfigMap data is available at the mount path:$ cat /etc/my-config/settings.json - For
envmounts, verify the environment variables are set:$ echo $LOG_LEVEL