v1alpha1

package
v0.1.0-alpha.1 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the ipam v1alpha1 API group +kubebuilder:object:generate=true +groupName=ipam.cluster.x-k8s.io

Index

Constants

View Source
const (
	NetboxIPPoolKind = "NetboxIPPool"
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "ipam.cluster.x-k8s.io", Version: "v1alpha1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)
View Source
var (
	PrefixType  = NetboxPoolType("Prefix")
	IPRangeType = NetboxPoolType("IPRange")
)

Functions

This section is empty.

Types

type NetboxIPPool

type NetboxIPPool struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   NetboxIPPoolSpec   `json:"spec,omitempty"`
	Status NetboxIPPoolStatus `json:"status,omitempty"`
}

NetboxIPPool is the Schema for the netboxippools API

func (*NetboxIPPool) DeepCopy

func (in *NetboxIPPool) DeepCopy() *NetboxIPPool

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

func (*NetboxIPPool) DeepCopyInto

func (in *NetboxIPPool) DeepCopyInto(out *NetboxIPPool)

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

func (*NetboxIPPool) DeepCopyObject

func (in *NetboxIPPool) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NetboxIPPoolList

type NetboxIPPoolList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []NetboxIPPool `json:"items"`
}

NetboxIPPoolList contains a list of NetboxIPPool

func (*NetboxIPPoolList) DeepCopy

func (in *NetboxIPPoolList) DeepCopy() *NetboxIPPoolList

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

func (*NetboxIPPoolList) DeepCopyInto

func (in *NetboxIPPoolList) DeepCopyInto(out *NetboxIPPoolList)

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

func (*NetboxIPPoolList) DeepCopyObject

func (in *NetboxIPPoolList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NetboxIPPoolSpec

type NetboxIPPoolSpec struct {
	// Type of the pool. Can either be Prefix or IPRange
	// +kubebuilder:validation:Enum=Prefix;IPRange
	Type NetboxPoolType `json:"type"`

	// Depending on the type, an Address is either the prefix or the start address of an ip-range, in CIDR notation.
	Address string `json:"address"`

	// Vrf where the Address is part of. If not provided, the "Global" Vrf is used.
	// +optional
	Vrf string `json:"vrf,omitempty"`

	// Gateway
	// +optional
	Gateway string `json:"gateway,omitempty"`

	// CredentialsRef is a reference to a Secret that contains the credentials to use for accessing th Netbox instance.
	// if no namespace is provided, the namespace of the NetboxIPPool will be used.
	CredentialsRef *corev1.SecretReference `json:"credentialsRef,omitempty"`
}

NetboxIPPoolSpec defines the desired state of NetboxIPPool

func (*NetboxIPPoolSpec) DeepCopy

func (in *NetboxIPPoolSpec) DeepCopy() *NetboxIPPoolSpec

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

func (*NetboxIPPoolSpec) DeepCopyInto

func (in *NetboxIPPoolSpec) DeepCopyInto(out *NetboxIPPoolSpec)

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

type NetboxIPPoolStatus

type NetboxIPPoolStatus struct {
	// Addresses reports the count of total, free, and used IPs in the pool.
	// +optional
	Addresses *NetboxPoolStatusIPAddresses `json:"ipAddresses,omitempty"`
}

NetboxIPPoolStatus defines the observed state of NetboxIPPool

func (*NetboxIPPoolStatus) DeepCopy

func (in *NetboxIPPoolStatus) DeepCopy() *NetboxIPPoolStatus

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

func (*NetboxIPPoolStatus) DeepCopyInto

func (in *NetboxIPPoolStatus) DeepCopyInto(out *NetboxIPPoolStatus)

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

type NetboxPoolStatusIPAddresses

type NetboxPoolStatusIPAddresses struct {
	// Total is the total number of IPs configured for the pool.
	// Counts greater than int can contain will report as math.MaxInt.
	Total int `json:"total"`

	// Free is the count of unallocated IPs in the pool.
	// Counts greater than int can contain will report as math.MaxInt.
	Free int `json:"free"`

	// Used is the count of allocated IPs in the pool.
	// Counts greater than int can contain will report as math.MaxInt.
	Used int `json:"used"`
}

NetboxPoolStatusIPAddresses contains the count of total, free, and used IPs in a pool.

func (*NetboxPoolStatusIPAddresses) DeepCopy

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

func (*NetboxPoolStatusIPAddresses) DeepCopyInto

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

type NetboxPoolType

type NetboxPoolType string

Jump to

Keyboard shortcuts

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