utils

package
v0.0.0-...-42d9681 Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultRegion = "ca-central-1"
	TimeOut       = 2 * time.Minute

	LAMBDA_NAMES_ENV_VAR      = "LAMBDA_NAMES"
	LAMBDA_REPOS_ENV_VAR      = "LAMBDA_IMAGE_REPOS"
	LAMBDA_IMAGE_TAGS_ENV_VAR = "LAMBDA_IMAGE_TAGS"
)

Variables

This section is empty.

Functions

func GetAWSConfig

func GetAWSConfig(ctx context.Context) (*aws.Config, error)

func GetAWSRegion

func GetAWSRegion() string

func GetLambdaClient

func GetLambdaClient(config aws.Config) *lambda.Client

func GetLambdaMapping

func GetLambdaMapping() map[string]string

Types

type Event

type Event struct {
	Detail  EventDetail `json:"detail"`
	Account string      `json:"account"`
	Region  string      `json:"region"`
}

type EventDetail

type EventDetail struct {
	ActionType     string `json:"action-type"`
	ImageDigest    string `json:"image-digest"`
	ImageTag       string `json:"image-tag"`
	RepositoryName string `json:"repository-name"`
	Result         string `json:"result"`
}

type ImageTagFilter

type ImageTagFilter func(tag string) bool

func GetImageTagFilter

func GetImageTagFilter() ImageTagFilter

Jump to

Keyboard shortcuts

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