discovery

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

package discovery implements a way to retrieve discovery information from Kubernetes to determine whether resources are namespace or cluster scoped.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIServerResourceInspector

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

APIServerResourceInspector implements ResourceInspector using the Kubernetes discovery API. It relies on a Kubernetes apiserver that has discovery information for all inputted resource types.

func NewAPIServerResourceInspector

func NewAPIServerResourceInspector(cfg *rest.Config) (*APIServerResourceInspector, error)

func (*APIServerResourceInspector) IsNamespaced

type ResourceInspector

type ResourceInspector interface {
	// IsNamespaced returns true if the given GroupVersionKind is for a
	// namespace-scoped object.
	IsNamespaced(schema.GroupVersionKind) (bool, error)
}

Jump to

Keyboard shortcuts

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