models

package
v0.0.0-...-4748bbb Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DBSnapshots

func DBSnapshots() ([]*rds.DBSnapshot, error)

DBSnapshots returns a slice of RDS Snapshots.

func DefaultSession

func DefaultSession() *session.Session

DefaultSession creates and initializes the underlying default session for working with models.

func DescribeDBLogFiles

func DescribeDBLogFiles(dbInstanceIdentifier string) ([]*rds.DescribeDBLogFilesDetails, error)

DescribeDBLogFiles returns details about the log files for a given DB Instance identifier

func EC2Client

func EC2Client(client *ec2.EC2)

EC2Client sets the client to be used by the models.

func GetBucketReplication

func GetBucketReplication(bucket *s3.Bucket) (*s3.GetBucketReplicationOutput, error)

GetBucketReplication returns the Replication status of the bucket

func GetRDSLogDownloadURL

func GetRDSLogDownloadURL(dbInstanceIdentifier string, fileName string) (*http.Request, error)

GetRDSLogDownloadURL returns a signed request for the given DB Instance identifier and filename

func IAMAccessKeyLastUsed

func IAMAccessKeyLastUsed(accessKeyID string) (*iam.GetAccessKeyLastUsedOutput, error)

func IAMAccessKeysMeatadata

func IAMAccessKeysMeatadata(username string) ([]*iam.AccessKeyMetadata, error)

IAMAccessKeysMetadata returns all AccessKeyMetadata

func IAMClient

func IAMClient(client *iam.IAM)

IAMClient sets the client to be used by the models.

func IAMUsers

func IAMUsers() ([]*iam.User, error)

IAM Users returns the list of IAM users

func Init

func Init(s *session.Session)

Init initializes the clients used by the models.

func Instances

func Instances(IDs []string) (instances []*ec2.Instance, err error)

Instances retrieves a list of instances by their instance IDs and returns an error if one occured.

func ListBuckets

func ListBuckets() ([]*s3.Bucket, error)

ListBuckets returns a list of buckets

func NetworkInterfaces

func NetworkInterfaces() ([]*ec2.NetworkInterface, error)

NetworkInterfaces returns all of the network interfaces or an error if one occured.

func RDSClient

func RDSClient(client *rds.RDS)

RDSClient sets the client to be used by the models.

func ReservedDBInstances

func ReservedDBInstances() ([]*rds.ReservedDBInstance, error)

ReservedDBInstances returns a slice of active reserved db instances. We have to do client side filtering since the API doesn't support filters at this time.

func ReservedInstances

func ReservedInstances() ([]*ec2.ReservedInstances, error)

ReservedInstances returns a slice of reserved instances.

func RunningDBInstances

func RunningDBInstances() ([]*rds.DBInstance, error)

RunningDBInstances returns a slice of running db instances.

func RunningInstances

func RunningInstances(opts RunningInstancesOpts) []*ec2.Instance

RunningInstances returns a slice of running instances

func S3Client

func S3Client(client *s3.S3)

S3Client sets the client to be used by the models.

func SecurityGroups

func SecurityGroups() ([]*ec2.SecurityGroup, error)

SecurityGroups returns all of the security groups or an error if one occured.

func SpotInstanceRequests

func SpotInstanceRequests(requestIDs []string) (reqs []*ec2.SpotInstanceRequest, err error)

SpotInstanceRequests returns a slice of spot instance requests by their IDs and an error if one occurs.

func Subnets

func Subnets() ([]*ec2.Subnet, error)

Subnets returns a list of subnets

func VPCs

func VPCs() ([]*ec2.Vpc, error)

VPCs returns a list of VPCs

Types

type RunningInstancesOpts

type RunningInstancesOpts struct {
	IncludeSpot bool
}

RunningInstancesOpts are options that can be passed to the running instances call.

Jump to

Keyboard shortcuts

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