Difference between revisions of "VolumeMounts:"

From wikieduonline
Jump to navigation Jump to search
Tags: Mobile web edit, Mobile edit
Tags: Mobile web edit, Mobile edit
Line 22: Line 22:
  
  
     [[volumeMounts:
+
     [[volumeMounts]]:
 
     - mountPath: /data
 
     - mountPath: /data
 
       name: persistent-storage
 
       name: persistent-storage

Revision as of 09:33, 8 March 2023

apiVersion: v1 
kind: Pod
metadata:
  name: test-ebs
spec:
  containers:
  - image: registry.k8s.io/test-webserver
    name: test-container
    volumeMounts:
    - mountPath: /test-ebs
      name: test-volume
  volumes:
  - name: test-volume
    # This AWS EBS volume must already exist.
    awsElasticBlockStore:
      volumeID: "<volume id>"
      fsType: ext4


   volumeMounts:
   - mountPath: /data
     name: persistent-storage
   - mountPath: /var/run/secrets/kubernetes.io/serviceaccount
     name: kube-api-access-jhnds
     readOnly: true

Related

See also

Advertising: