kubernetes

package
v0.6.138 Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddKubeconfigFlag

func AddKubeconfigFlag(cmd *cobra.Command)

func NamespacedName

func NamespacedName(name string) (*types.NamespacedName, error)

NamespacedName constructs a NamespacedName from the provided name by either splitting it with the default spearator or augmenting it with the namespace selected in the Kubernetes Context configuration.

func WithClient

func WithClient(ctx context.Context, client Client) context.Context

Types

type Client

type Client interface {
	FetchEnterpriseContractPolicy(ctx context.Context, ref string) (*ecc.EnterpriseContractPolicy, error)
	FetchSnapshot(ctx context.Context, ref string) (*app.Snapshot, error)
}

func NewClient

func NewClient(ctx context.Context) (Client, error)

NewClient constructs a new kubernetes with the default "live" client

Jump to

Keyboard shortcuts

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