Documentation ¶
Index ¶
Constants ¶
View Source
const ( //CredentialFile is the path of oss ak credential file CredentialFile = "/host/etc/passwd-ossfs" // NsenterCmd is nsenter mount command NsenterCmd = "/nsenter --mount=/proc/1/ns/mnt" // SocketPath is path of connector sock SocketPath = "/host/etc/csi-tool/connector.sock" // AkID is Ak ID AkID = "akId" // AkSecret is Ak Secret AkSecret = "akSecret" // OssFsType is the oss filesystem type OssFsType = "fuse.ossfs" // JindoFsType tag JindoFsType = "jindofs" // JindofsCredentialPathInPod Pod side sts file JindofsCredentialPathInPod = "/oss-secret/sts-token" // JindofsCredentialPathOnHost Host side sts file JindofsCredentialPathOnHost = "/host/etc/jindofs-credentials" )
View Source
const ( // MetadataURL is metadata url MetadataURL = "http://100.100.100.200/latest/meta-data/" // InstanceID is instance ID InstanceID = "instance-id" // RAMRoleResource is ram-role url subpath RAMRoleResource = "ram/security-credentials/" )
Variables ¶
View Source
var ( filepath.Join(utils.KubeletRootDir, "/plugins/kubernetes.io/csi/pv/%s/globalmount") )SharedPath =
Functions ¶
func GetMetaData ¶ added in v1.0.1
GetMetaData get host regionid, zoneid
func GetRAMRoleOption ¶ added in v1.0.5
GetRAMRoleOption get command line's ram_role option
func IsHostMounted ¶ added in v1.0.1
IsHostMounted return status of host mounted or not
func IsLastSharedVol ¶ added in v1.0.3
IsLastSharedVol return code status to help check if this oss volume uses UseSharedPath and is the last one
func IsOssfsMounted ¶ added in v1.0.3
IsOssfsMounted return if oss mountPath is mounted
Types ¶
type OSS ¶ added in v1.0.1
type OSS struct {
// contains filtered or unexported fields
}
OSS the OSS object
type Options ¶ added in v1.0.1
type Options struct { Bucket string `json:"bucket"` URL string `json:"url"` OtherOpts string `json:"otherOpts"` AkID string `json:"akId"` AkSecret string `json:"akSecret"` Path string `json:"path"` AuthType string `json:"authType"` FuseType string `json:"fuseType"` }
Options contains options for target oss
Click to show internal directories.
Click to hide internal directories.