handlers

package
v0.0.0-...-507e24d Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const DenyAllNetpol = "deny-all"

DenyAllNetpol defines the deny all netpol name

View Source
const DenyIngressNetpol = "deny-ingress"

DenyIngressNetpol defines the deny all netpol name

Variables

This section is empty.

Functions

func DeletePreviousNetpols

func DeletePreviousNetpols(e event.Event, client kubernetes.Interface, current string) (err error)

DeletePreviousNetpols deletes previous applied network policies

Types

type Handler

type Handler interface {
	Init(c *config.Config) error
	Handle(e event.Event, c kubernetes.Interface)
}

Handler is implemented by any handler. The Handle method is used to process event

type HandlerConfig

type HandlerConfig struct {
	NetPol config.NetPol
}

HandlerConfig hadler configuration

func (*HandlerConfig) Handle

func (h *HandlerConfig) Handle(e event.Event, client kubernetes.Interface)

Handle handles an event.

func (*HandlerConfig) Init

func (h *HandlerConfig) Init(c *config.Config) error

Init initializes handler configuration

Jump to

Keyboard shortcuts

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