We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
apiVersion: v1 kind: ConfigMap metadata: name: core-env data: .foo: | APP=xxx .bar: | APP=xxx
- mountPath: /var/www/html/.foo name: env-config subPath: .foo volumes: - name: env-config configMap: name: core-env defaultMode: 420
此處只會將 configmap 內的 .foo key 的內容掛載進去 和下面的方式主要差異在於,上面是將內容直接以檔案形式放進去,不會影響到 /var/www/html/ 裡的內容 下面為將 volume 掛在 /etc/config,此方式會導致原先在 /etc/config 內的東西消失
/var/www/html/
/etc/config
apiVersion: v1 kind: Pod metadata: name: configmap-pod spec: containers: - name: test image: busybox volumeMounts: - name: config-vol mountPath: /etc/config volumes: - name: config-vol configMap: name: log-config items: - key: log_level path: log_level
The text was updated successfully, but these errors were encountered:
No branches or pull requests
此處只會將 configmap 內的 .foo key 的內容掛載進去
和下面的方式主要差異在於,上面是將內容直接以檔案形式放進去,不會影響到
/var/www/html/
裡的內容下面為將 volume 掛在
/etc/config
,此方式會導致原先在/etc/config
內的東西消失The text was updated successfully, but these errors were encountered: