efs

package
v0.13.1 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2023 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrCode

func ErrCode(msg string, err error) error

Types

type EFS

type EFS struct {
	Service         efsiface.EFSAPI
	DefaultKmsKeyId string
	DefaultSgs      []string
	DefaultSubnets  []string
	// contains filtered or unexported fields
}

EFS is a wrapper around the aws EFS service with some default config info

func New added in v0.11.0

func New(opts ...EFSOption) EFS

func NewSession

func NewSession(account common.Account) EFS

NewSession creates a new EFS session

func (*EFS) CreateAccessPoint added in v0.9.0

func (e *EFS) CreateAccessPoint(ctx context.Context, input *efs.CreateAccessPointInput) (*efs.CreateAccessPointOutput, error)

func (*EFS) CreateFileSystem

func (e *EFS) CreateFileSystem(ctx context.Context, input *efs.CreateFileSystemInput) (*efs.FileSystemDescription, error)

CreateFilesystem creates an EFS filesystem

func (*EFS) CreateMountTarget

func (e *EFS) CreateMountTarget(ctx context.Context, input *efs.CreateMountTargetInput) (*efs.MountTargetDescription, error)

CreateMountTarget creates an EFS mount target

func (EFS) DeleteAccessPoint added in v0.9.0

func (e EFS) DeleteAccessPoint(ctx context.Context, apid string) error

func (*EFS) DeleteFileSystem

func (e *EFS) DeleteFileSystem(ctx context.Context, id string) error

DeleteFilsystem deletes an EFS filesystem

func (*EFS) DeleteMountTarget

func (e *EFS) DeleteMountTarget(ctx context.Context, id string) error

DeleteMountTarget deletes mount targets

func (EFS) GetAccessPoint added in v0.9.0

func (e EFS) GetAccessPoint(ctx context.Context, apid string) (*efs.AccessPointDescription, error)

func (*EFS) GetFileSystem

func (e *EFS) GetFileSystem(ctx context.Context, id string) (*efs.FileSystemDescription, error)

GetFilesystem gets details about a filesystem

func (*EFS) GetFileSystemPolicy added in v0.12.0

func (e *EFS) GetFileSystemPolicy(ctx context.Context, id string) (string, error)

func (*EFS) GetFilesystemBackup added in v0.4.0

func (e *EFS) GetFilesystemBackup(ctx context.Context, id string) (string, error)

GetFilesystemBackup gets the backup policy status for a filesystem

func (*EFS) GetFilesystemLifecycle added in v0.3.0

func (e *EFS) GetFilesystemLifecycle(ctx context.Context, id string) (string, string, error)

GetFilesystemLifecycle gets the lifecycle transition configuration for a filesystem

func (EFS) ListAccessPoints added in v0.9.0

func (e EFS) ListAccessPoints(ctx context.Context, fsid string) ([]*efs.AccessPointDescription, error)

func (*EFS) ListFileSystems

func (e *EFS) ListFileSystems(ctx context.Context, input *efs.DescribeFileSystemsInput) ([]string, error)

ListFilesystems lists all filesystems if nil input is passed

func (*EFS) ListMountTargetsForFileSystem

func (e *EFS) ListMountTargetsForFileSystem(ctx context.Context, id string) ([]*efs.MountTargetDescription, error)

ListMountTargetsForFileSystem lists the mount targets for a filesystem - there should never be more than 2 since you're only allowed one per AZ

func (*EFS) SetFileSystemBackup added in v0.4.0

func (e *EFS) SetFileSystemBackup(ctx context.Context, id, status string) error

SetFileSystemBackup sets a lifecycle transition policy on a filesystem

func (*EFS) SetFileSystemLifecycle added in v0.3.0

func (e *EFS) SetFileSystemLifecycle(ctx context.Context, id, transitionToIA, transitionToPrimary string) error

SetFileSystemLifecycle sets a lifecycle transition policy on a filesystem

func (*EFS) SetFileSystemPolicy added in v0.12.0

func (e *EFS) SetFileSystemPolicy(ctx context.Context, id, policy string) error

func (*EFS) TagFilesystem added in v0.5.0

func (e *EFS) TagFilesystem(ctx context.Context, id string, tags []*efs.Tag) error

type EFSOption added in v0.11.0

type EFSOption func(*EFS)

func WithCredentials added in v0.11.0

func WithCredentials(key, secret, token, region string) EFSOption

func WithDefaultKMSKeyId added in v0.11.0

func WithDefaultKMSKeyId(accountNumber, keyId string) EFSOption

func WithDefaultSgs added in v0.11.0

func WithDefaultSgs(sgs []string) EFSOption

func WithDefaultSubnets added in v0.11.0

func WithDefaultSubnets(subnets []string) EFSOption

func WithSession added in v0.11.0

func WithSession(sess *session.Session) EFSOption

Jump to

Keyboard shortcuts

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