common

package
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 13, 2022 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ParamDriverName string = "driverName"

	DefaultEndpoint   string = "unix://tmp/csi.sock"
	DefaultDriverName string = "object.csi.aliyun.com"

	HostDir             string = "/host"
	ConfigDir           string = "/etc/open-object"
	ConnectorSocketName string = "connector.sock"

	NsenterCmd = "/bin/nsenter --mount=/proc/1/ns/mnt --ipc=/proc/1/ns/ipc --net=/proc/1/ns/net --uts=/proc/1/ns/uts "

	// VolumeOperationAlreadyExists is message fmt returned to CO when there is another in-flight call on the given volumeID
	VolumeOperationAlreadyExists = "An operation with the given volume=%q is already in progress"
)

Variables

View Source
var (
	// ConnectorWorkPath workspace
	ConnectorWorkPath = "./"
	// ConnectorSocketPath socket path
	ConnectorSocketPath = filepath.Join(ConfigDir, "connector.sock")
	// ConnectorLogFilename name of log file
	ConnectorLogFilename = filepath.Join(ConfigDir, "connector.log")
	// ConnectorPIDFilename name of pid file
	ConnectorPIDFilename = filepath.Join(ConfigDir, "connector.pid")
)

Functions

func ConnectorRunInContainer

func ConnectorRunInContainer(cmd string) (string, error)

func FuseMount

func FuseMount(path string, command string, args []string) error

func FuseUmount

func FuseUmount(path string) error

func IsDirExisting

func IsDirExisting(filename string) bool

IsDirExisting checks dir exist

func RunCommand

func RunCommand(cmd string) (string, error)

func RunConnector

func RunConnector()

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL