Documentation ¶
Index ¶
- Constants
- type Decryptor
- type FlexVolume
- func (sv *FlexVolume) Attach(params map[string]interface{}) (string, error)
- func (sv *FlexVolume) Create(options map[string]interface{}) (map[string]interface{}, error)
- func (sv *FlexVolume) Delete(options map[string]interface{}) error
- func (sv *FlexVolume) Detach(device string) error
- func (sv *FlexVolume) Init() error
- func (sv *FlexVolume) Mount(dir, device string, params map[string]interface{}) error
- func (sv *FlexVolume) Unmount(dir string) error
- type SecretGetter
- type SecretWriter
Constants ¶
const ( // DefaultMode is readable only by user DefaultMode = "0444" //DefaultUID is Root DefaultUID = "0" //DefaultGID is Roots default group DefaultGID = "0" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Decryptor ¶
Decryptor handles decrypting messages
func NewRSADecryptor ¶
NewRSADecryptor returns an RSA decryptor
type FlexVolume ¶
type FlexVolume struct {
// contains filtered or unexported fields
}
FlexVolume is a struct to implement the Rancher Volume interface
func (*FlexVolume) Attach ¶
func (sv *FlexVolume) Attach(params map[string]interface{}) (string, error)
Attach is implemeneted as a no-op for the flexvolume API
func (*FlexVolume) Create ¶
func (sv *FlexVolume) Create(options map[string]interface{}) (map[string]interface{}, error)
Create is implemented for Docker volume plugin API
func (*FlexVolume) Delete ¶
func (sv *FlexVolume) Delete(options map[string]interface{}) error
Delete is implemented for Docker volume plugin API it detaches the volume and removes its content.
func (*FlexVolume) Detach ¶
func (sv *FlexVolume) Detach(device string) error
Detach effectively erases the volume.
func (*FlexVolume) Init ¶
func (sv *FlexVolume) Init() error
Init implements the flex volume interface and is a no-op at this time
func (*FlexVolume) Mount ¶
func (sv *FlexVolume) Mount(dir, device string, params map[string]interface{}) error
Mount implements does a bind mount of the volume to the target directory
func (*FlexVolume) Unmount ¶
func (sv *FlexVolume) Unmount(dir string) error
Unmount undoes the bind mount, and removes the target directory
type SecretGetter ¶
type SecretGetter interface {
GetSecrets(params *options) ([]secret, error)
}
SecretGetter gets the secrets froma remote source
func NewRancherSecretGetter ¶
func NewRancherSecretGetter(params *options) (SecretGetter, error)
NewRancherSecretGetter returns a new rancherSecretGetter
type SecretWriter ¶
SecretWriter implements the Writer interface
func NewRSASecretFileWriter ¶
func NewRSASecretFileWriter(decryptor Decryptor) (SecretWriter, error)
NewRSASecretFileWriter returns a SecretWriter implemenation to talk to Rancher