event

package
v1.8.5 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2019 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EventTypeImagePush   = "image_push"
	EventTypeImageDelete = "image_delete"
	EventTypeChartUpload = "chart_upload"
	EventTypeChartDelete = "chart_delete"
)

const definitions

Variables

This section is empty.

Functions

func GetLocalRegistry added in v1.8.0

func GetLocalRegistry() *model.Registry

GetLocalRegistry returns the info of the local Harbor registry

func PopulateRegistries added in v1.8.0

func PopulateRegistries(registryMgr registry.Manager, policy *model.Policy) error

PopulateRegistries populates the source registry and destination registry properties for policy

Types

type Event added in v1.8.0

type Event struct {
	Type     string
	Resource *model.Resource
}

Event is the model that defines the image/chart pull/push event

type Handler added in v1.8.0

type Handler interface {
	Handle(event *Event) error
}

Handler is the handler to handle event

func NewHandler added in v1.8.0

func NewHandler(policyCtl policy.Controller, registryMgr registry.Manager, opCtl operation.Controller) Handler

NewHandler ...

Jump to

Keyboard shortcuts

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