app

package
v0.0.0-...-ed96a3d Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2022 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Default           = iota // (not verbose) Show ports and their results
	DetailMatching           // (-v) Show all ports and the network policies that match both pods
	DetailNotMatching        // (-vv) Show all ports and all network policies
)

Variables

This section is empty.

Functions

func RenderCheckAccess

func RenderCheckAccess(v ConsoleView, portResults []eval.PortResult, source, dest eval.ConnectionSide) error

func RenderNetPolMatch

func RenderNetPolMatch(matches []nwv1.NetworkPolicy)

Types

type App

type App struct {
	// contains filtered or unexported fields
}

func NewApp

func NewApp(kubeconfig string) (*App, error)

func (*App) CheckAccess

func (a *App) CheckAccess(v ConsoleView,
	namespaceName string,
	podName string,
	toNamespaceName string,
	toPodName string,
	toPortStr string,
	toExternalIP string,
	toProtocolName string) error

func (*App) InspectEgress

func (a *App) InspectEgress(namespace string, podName string) error

type ConsoleView

type ConsoleView struct {
	Writer *bufio.Writer
	Verbosity
}

func NewConsoleView

func NewConsoleView(v int) ConsoleView

func (ConsoleView) Flush

func (c ConsoleView) Flush()

type Verbosity

type Verbosity uint8

func GetVerbosity

func GetVerbosity(flags int) Verbosity

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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