snapshot

package
v0.0.0-...-d7bfa4f Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BulkDeleteConfig

type BulkDeleteConfig struct {
	Region          string
	Profile         string
	AccessKeyID     string
	SecretAccessKey string
	SessionToken    string
	Verbose         bool

	Plan bool

	Age  uint
	Tags []string
}

type BullDelete

type BullDelete struct {
	// contains filtered or unexported fields
}

func NewBulkDelete

func NewBulkDelete(cfg *BulkDeleteConfig) (*BullDelete, error)

func (*BullDelete) Run

func (c *BullDelete) Run(ctx context.Context) error

func (*BullDelete) RunWithOptions

func (c *BullDelete) RunWithOptions(ctx context.Context, opts Options) error

type EC2SnapshotAPI

type EC2SnapshotAPI interface {
	DescribeSnapshotsPagesWithContext(ctx aws.Context, input *ec2.DescribeSnapshotsInput, fn func(*ec2.DescribeSnapshotsOutput, bool) bool, opts ...request.Option) error
	DeleteSnapshotWithContext(ctx aws.Context, input *ec2.DeleteSnapshotInput, opts ...request.Option) (*ec2.DeleteSnapshotOutput, error)
}

type ErrorWithSnapshot

type ErrorWithSnapshot struct {
	Error    error
	Snapshot *ec2.Snapshot
}

type Options

type Options struct {
	BeforeDescribeSnapshotsFunc func() error
	AfterDescribeSnapshotsFunc  func(snapshots []*ec2.Snapshot) error
	BeforeDeleteSnapshotsFunc   func(snapshots []*ec2.Snapshot) error
	EachDeleteSnapshotsFunc     func(snapshot *ec2.Snapshot) error
	AfterDeleteSnapshotsFunc    func(successful []*ec2.Snapshot, failed []*ErrorWithSnapshot) error
}

Jump to

Keyboard shortcuts

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