Difference between revisions of "Kubernetes projected volumes"
Jump to navigation
Jump to search
Tags: Mobile web edit, Mobile edit |
Tags: Mobile web edit, Mobile edit |
||
(9 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | + | * https://kubernetes.io/docs/concepts/storage/projected-volumes/ | |
+ | |||
+ | A projected volume maps several existing volume sources into the same directory. | ||
+ | |||
+ | Currently, the following types of volume sources can be projected: | ||
+ | * <code>[[secret]]</code> | ||
+ | * <code>[[downwardAPI]]</code> | ||
+ | * <code>[[configMap]]</code> | ||
+ | * <code>[[serviceAccountToken]]</code> | ||
+ | |||
+ | |||
− | |||
volumes: | volumes: | ||
- name: persistent-storage | - name: persistent-storage | ||
persistentVolumeClaim: | persistentVolumeClaim: | ||
− | claimName: pvc-ebs-redis-api | + | claimName: pvc-ebs-redis-api |
- name: kube-api-access-jhnds | - name: kube-api-access-jhnds | ||
projected: | projected: | ||
− | defaultMode: 420 | + | [[defaultMode]]: 420 |
sources: | sources: | ||
− | - serviceAccountToken: | + | - [[serviceAccountToken]]: |
expirationSeconds: 3607 | expirationSeconds: 3607 | ||
path: token | path: token | ||
− | - configMap: | + | - [[configMap]]: |
items: | items: | ||
- key: ca.crt | - key: ca.crt | ||
path: ca.crt | path: ca.crt | ||
name: kube-root-ca.crt | name: kube-root-ca.crt | ||
− | - downwardAPI: | + | - [[downwardAPI]]: |
items: | items: | ||
- fieldRef: | - fieldRef: | ||
Line 24: | Line 33: | ||
fieldPath: metadata.namespace | fieldPath: metadata.namespace | ||
path: namespace | path: namespace | ||
− | + | ||
Line 36: | Line 45: | ||
== See also == | == See also == | ||
− | * {{K8s}} | + | * {{K8s storage}} |
+ | |||
+ | [[Category:K8s]] |
Latest revision as of 10:12, 8 March 2023
A projected volume maps several existing volume sources into the same directory.
Currently, the following types of volume sources can be projected:
volumes: - name: persistent-storage persistentVolumeClaim: claimName: pvc-ebs-redis-api - name: kube-api-access-jhnds projected: defaultMode: 420 sources: - serviceAccountToken: expirationSeconds: 3607 path: token - configMap: items: - key: ca.crt path: ca.crt name: kube-root-ca.crt - downwardAPI: items: - fieldRef: apiVersion: v1 fieldPath: metadata.namespace path: namespace
kubectl get psp Warning: policy/v1beta1 PodSecurityPolicy is deprecated in v1.21+, unavailable in v1.25+ NAME PRIV CAPS SELINUX RUNASUSER FSGROUP SUPGROUP READONLYROOTFS VOLUMES gce.gke-metrics-agent false RunAsAny RunAsAny RunAsAny RunAsAny false hostPath,secret,configMap grafana false RunAsAny RunAsAny RunAsAny RunAsAny false configMap,emptyDir,projected,secret,downwardAPI,persistentVolumeClaim
See also[edit]
- Kubernetes storage, storage classes, PersistentVolume (PV), PVC, CSI,
kind: StorageClass, kind: PersistentVolumeClaim, kind: PersistentVolume
,kubectl [ get | describe | edit ] pvc
,volumeClaimTemplates:
,kubectl patch pv
,FailedMount
, Volume Expansion, Volume Cloning, snapshots, ExtraVolumes, NotTriggerScaleUp,volumePVCDataSource, AllowVolumeExpansion
, EKS storage, provisioner, Storage Capacity Tracking,VolumeBinding, VolumeClaimTemplate, storage.k8s.io
, CKA Storage, DoKC, EmptyDir, Volume populators,storageclass.kubernetes.io
Advertising: