Documentation
¶
Overview ¶
Package hp3par holds what the drivers of an HPE 3PAR array have in common: how a command line is built for the array, and how it is run.
The array driver and the disk driver reach the same arrays, and there is one way of reaching them. The shapes here are the ones the disk driver has been run with against real hardware on recent firmware, which is why they are here rather than in each driver.
Index ¶
Constants ¶
const ( // MethodSSH runs the command on the array, over ssh. MethodSSH = "ssh" // MethodCLI runs the command through the 3par cli installed here. MethodCLI = "cli" )
Variables ¶
var ErrBuildCommand = errors.New("build command")
ErrBuildCommand is raised when the configuration does not say enough to reach the array.
Functions ¶
func Clean ¶
Clean removes the carriage returns and the trailing blank lines of what the array printed.
Types ¶
type Config ¶
type Config struct {
// Method is ssh or cli.
Method string
// Manager is the array, by name or address.
Manager string
// Username is who to log in as, over ssh.
Username string
// KeyFile is the ssh private key to log in with.
KeyFile string
// CLI is the 3par cli binary, for the cli method.
CLI string
// PWFile is the password file the cli authenticates with.
PWFile string
}
Config is how one array is reached.
The paths are resolved: a key or a password file named in the configuration as a reference to a datastore is materialised by the caller, which knows what the reference is relative to.