reference

package
v0.5.2 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2023 License: Apache-2.0 Imports: 9 Imported by: 4

Documentation

Overview

Package reference provides a way to reference Kubernetes resources.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LocalConfigMapReference added in v0.2.0

type LocalConfigMapReference struct {
	// Name is the name of the config map.
	Name string `json:"name"`
}

LocalConfigMapReference is a reference to a config map in the same namespace. +kubebuilder:object:generate=true

func (*LocalConfigMapReference) DeepCopy added in v0.2.0

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalConfigMapReference.

func (*LocalConfigMapReference) DeepCopyInto added in v0.2.0

func (in *LocalConfigMapReference) DeepCopyInto(out *LocalConfigMapReference)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*LocalConfigMapReference) Resolve added in v0.2.0

func (ref *LocalConfigMapReference) Resolve(ctx context.Context, reader client.Reader, scheme *runtime.Scheme, parent runtime.Object) (runtime.Object, bool, error)

Resolve resolves the reference to its underlying config map.

type LocalKeyedSecretReference added in v0.5.0

type LocalKeyedSecretReference struct {
	*LocalSecretReference `json:",inline"`
	// Key is the key of the value in the secret.
	Key string `json:"key"`
}

LocalKeyedSecretReference is a reference to a secret in the same namespace containing a single keyed value. +kubebuilder:object:generate=true

func (*LocalKeyedSecretReference) DeepCopy added in v0.5.0

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalKeyedSecretReference.

func (*LocalKeyedSecretReference) DeepCopyInto added in v0.5.0

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LocalObjectReference added in v0.3.3

type LocalObjectReference struct {
	// Name is the name of the resource.
	Name string `json:"name,omitempty"`
	// APIVersion is the API version of the resource.
	APIVersion string `json:"apiVersion,omitempty"`
	// Kind is the kind of the resource.
	Kind string `json:"kind,omitempty"`
}

LocalObjectReference is a reference to a resource in the same namespace. +kubebuilder:object:generate=true

func (*LocalObjectReference) DeepCopy added in v0.3.3

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalObjectReference.

func (*LocalObjectReference) DeepCopyInto added in v0.3.3

func (in *LocalObjectReference) DeepCopyInto(out *LocalObjectReference)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*LocalObjectReference) Resolve added in v0.3.3

func (ref *LocalObjectReference) Resolve(ctx context.Context, reader client.Reader, scheme *runtime.Scheme, parent runtime.Object) (runtime.Object, bool, error)

Resolve resolves the reference to its underlying resource.

type LocalSecretReference

type LocalSecretReference struct {
	// Name is the name of the secret.
	Name string `json:"name"`
}

LocalSecretReference is a reference to a secret in the same namespace. +kubebuilder:object:generate=true

func (*LocalSecretReference) DeepCopy added in v0.2.0

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalSecretReference.

func (*LocalSecretReference) DeepCopyInto added in v0.2.0

func (in *LocalSecretReference) DeepCopyInto(out *LocalSecretReference)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*LocalSecretReference) Resolve

func (ref *LocalSecretReference) Resolve(ctx context.Context, reader client.Reader, scheme *runtime.Scheme, parent runtime.Object) (runtime.Object, bool, error)

Resolve resolves the reference to its underlying secret.

type ObjectReference

type ObjectReference struct {
	// Name is the name of the resource.
	Name string `json:"name,omitempty"`
	// Namespace is the namespace of the resource.
	Namespace string `json:"namespace,omitempty"`
	// APIVersion is the API version of the resource.
	APIVersion string `json:"apiVersion,omitempty"`
	// Kind is the kind of the resource.
	Kind string `json:"kind,omitempty"`
}

ObjectReference is a reference to an arbitrary Kubernetes resource. +kubebuilder:object:generate=true

func (*ObjectReference) DeepCopy added in v0.2.0

func (in *ObjectReference) DeepCopy() *ObjectReference

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ObjectReference.

func (*ObjectReference) DeepCopyInto added in v0.2.0

func (in *ObjectReference) DeepCopyInto(out *ObjectReference)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ObjectReference) Resolve

func (ref *ObjectReference) Resolve(ctx context.Context, reader client.Reader, scheme *runtime.Scheme, parent runtime.Object) (runtime.Object, bool, error)

Resolve resolves the reference to its underlying resource.

type ObjectWithReferences

type ObjectWithReferences interface {
	// ResolveReferences resolves all references in the object.
	ResolveReferences(ctx context.Context, reader client.Reader, scheme *runtime.Scheme) (bool, error)
}

type Reference

type Reference interface {
	// Resolve resolves the reference to its underlying resource.
	Resolve(ctx context.Context, reader client.Reader, scheme *runtime.Scheme, parent runtime.Object) (obj runtime.Object, ok bool, err error)
}

Jump to

Keyboard shortcuts

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