plugins_utils

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 25, 2019 License: Apache-2.0 Imports: 5 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

View Source
var PluginsCategories = map[string]string{
	"EC2": "EC2",
	"S3":  "S3",
}

PluginsCategories defines the categories that can be used for the plugins Any new category should be added in the map

Functions

func GetEc2ClientSession

func GetEc2ClientSession(creds *credentials.Credentials, region *string) *ec2.EC2

GetEc2ClientSession is a utility function to create an ec2 session it takes credentials and a region and returns an ec2 session

func GetS3ClientSession

func GetS3ClientSession(creds *credentials.Credentials) *s3.S3

GetS3ClientSession is a utility function to create an S3 session it takes credentials returns an S3 session

Types

type StatusPercentSteps

type StatusPercentSteps struct {
	MinOrange int
	MinGreen  int
}

StatusPercentSteps defines the steps used to compute the status Example: StatusPercentSteps{25, 75} A percentage between 0 and 24 will have a red status A percentage between 25 and 74 will have a orange status A percentage between 75 and 100 will have a green status A percentage < 0 or > 100 will have a red status

func (StatusPercentSteps) GetStatus

func (steps StatusPercentSteps) GetStatus(checked, passed int) string

GetStatus returns the status based on the parameters and on the configured steps

Jump to

Keyboard shortcuts

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