cmd

package
v0.0.0-...-25056e1 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2024 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewInitCmd

func NewInitCmd(buildInfo imgvuln.BuildInfo, cf *genericclioptions.ConfigFlags) *cobra.Command

func NewRootCmd

func NewRootCmd(buildInfo imgvuln.BuildInfo, args []string, outWriter io.Writer, errWriter io.Writer) *cobra.Command

func NewScanCmd

func NewScanCmd(buildInfo imgvuln.BuildInfo, cf *genericclioptions.ConfigFlags) *cobra.Command

func NewScanPolicyReportsCmd

func NewScanPolicyReportsCmd(buildInfo imgvuln.BuildInfo, cf *genericclioptions.ConfigFlags) *cobra.Command

func Run

func Run(version imgvuln.BuildInfo, args []string, outWriter io.Writer, errWriter io.Writer) error

Run is the entry point of the imgvuln CLI. It runs the specified command based on the specified args.

func ScanPolicyReports

func ScanPolicyReports(buildInfo imgvuln.BuildInfo, cf *genericclioptions.ConfigFlags) func(cmd *cobra.Command, args []string) error

func SetGlobalFlags

func SetGlobalFlags(cf *genericclioptions.ConfigFlags, cmd *cobra.Command)

func WorkloadFromArgs

func WorkloadFromArgs(mapper meta.RESTMapper, namespace string, args []string) (workload kube.Object, gvk schema.GroupVersionKind, err error)

func Write

func Write(r []policyreport.PolicyReport, kubeconfigPath string) error

Types

type Installer

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

func NewInstaller

func NewInstaller(
	buildInfo imgvuln.BuildInfo,

	clientset kubernetes.Interface,
	clientsetext extapi.ApiextensionsV1Interface,
	client client.Client,
	configManager imgvuln.ConfigManager,
) *Installer

NewInstaller constructs an Installer with the given imgvuln.ConfigManager and kubernetes.Interface.

func (*Installer) Install

func (m *Installer) Install(ctx context.Context) error

Jump to

Keyboard shortcuts

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