Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 12 of 12 for getVolumeSource (0.1 sec)

  1. pkg/volume/local/local.go

    	// The current meaning of AccessMode is how many nodes can attach to it, not how many pods can mount it
    	return []v1.PersistentVolumeAccessMode{
    		v1.ReadWriteOnce,
    	}
    }
    
    func getVolumeSource(spec *volume.Spec) (*v1.LocalVolumeSource, bool, error) {
    	if spec.PersistentVolume != nil && spec.PersistentVolume.Spec.Local != nil {
    		return spec.PersistentVolume.Spec.Local, spec.ReadOnly, nil
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue May 14 06:17:25 UTC 2024
    - 22.2K bytes
    - Viewed (0)
  2. pkg/volume/emptydir/empty_dir.go

    	return nil
    }
    
    func (plugin *emptyDirPlugin) GetPluginName() string {
    	return emptyDirPluginName
    }
    
    func (plugin *emptyDirPlugin) GetVolumeName(spec *volume.Spec) (string, error) {
    	volumeSource, _ := getVolumeSource(spec)
    	if volumeSource == nil {
    		return "", fmt.Errorf("Spec does not reference an EmptyDir volume type")
    	}
    
    	// Return user defined volume name, since this is an ephemeral volume type
    	return spec.Name(), nil
    }
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue May 21 10:18:16 UTC 2024
    - 19K bytes
    - Viewed (0)
Back to top