pts

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

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

Builder is the builder object for Pod

func NewBuilder

func NewBuilder() *Builder

NewBuilder returns new instance of Builder

func (*Builder) Build

func (b *Builder) Build() (*PodTemplateSpec, error)

Build returns a deployment instance

func (*Builder) WithAffinity

func (b *Builder) WithAffinity(affinity *corev1.Affinity) *Builder

WithAffinity sets the affinity field of podtemplatespec

func (*Builder) WithAnnotations

func (b *Builder) WithAnnotations(annotations map[string]string) *Builder

WithAnnotations merges existing annotations if any with the ones that are provided here

func (*Builder) WithAnnotationsNew

func (b *Builder) WithAnnotationsNew(annotations map[string]string) *Builder

WithAnnotationsNew resets the annotation field of podtemplatespec with provided arguments

func (*Builder) WithContainerBuilders

func (b *Builder) WithContainerBuilders(
	containerBuilderList ...*container.Builder,
) *Builder

WithContainerBuilders builds the list of containerbuilder provided and merges it to the containers field of the podtemplatespec

func (*Builder) WithContainerBuildersNew

func (b *Builder) WithContainerBuildersNew(
	containerBuilderList ...*container.Builder,
) *Builder

WithContainerBuildersNew builds the list of containerbuilder provided and sets the containers field of the podtemplatespec

func (*Builder) WithLabels

func (b *Builder) WithLabels(labels map[string]string) *Builder

WithLabels merges existing labels if any with the ones that are provided here

func (*Builder) WithLabelsNew

func (b *Builder) WithLabelsNew(labels map[string]string) *Builder

WithLabelsNew resets the labels field of podtemplatespec with provided arguments

func (*Builder) WithName

func (b *Builder) WithName(name string) *Builder

WithName sets the Name field of podtemplatespec with provided value.

func (*Builder) WithNamespace

func (b *Builder) WithNamespace(namespace string) *Builder

WithNamespace sets the Namespace field of PodTemplateSpec with provided value.

func (*Builder) WithNodeSelector

func (b *Builder) WithNodeSelector(nodeselectors map[string]string) *Builder

WithNodeSelector merges the nodeselectors if present with the provided arguments

func (*Builder) WithNodeSelectorNew

func (b *Builder) WithNodeSelectorNew(nodeselectors map[string]string) *Builder

WithNodeSelectorNew resets the nodeselector field of podtemplatespec with provided arguments

func (*Builder) WithServiceAccountName

func (b *Builder) WithServiceAccountName(serviceAccountnNme string) *Builder

WithServiceAccountName sets the ServiceAccountnNme field of podtemplatespec

func (*Builder) WithTolerations

func (b *Builder) WithTolerations(tolerations ...corev1.Toleration) *Builder

WithTolerations merges the existing tolerations with the provided arguments

func (*Builder) WithTolerationsNew

func (b *Builder) WithTolerationsNew(tolerations ...corev1.Toleration) *Builder

WithTolerationsNew sets the tolerations field of podtemplatespec

func (*Builder) WithVolumeBuilders

func (b *Builder) WithVolumeBuilders(
	volumeBuilderList ...*volume.Builder,
) *Builder

WithVolumeBuilders builds the list of volumebuilders provided and merges it to the volumes field of podtemplatespec.

func (*Builder) WithVolumeBuildersNew

func (b *Builder) WithVolumeBuildersNew(
	volumeBuilderList ...*volume.Builder,
) *Builder

WithVolumeBuildersNew builds the list of volumebuilders provided and sets Volumes field of podtemplatespec.

type PodTemplateSpec

type PodTemplateSpec struct {
	Object *corev1.PodTemplateSpec
}

PodTemplateSpec holds the api's podtemplatespec objects

Jump to

Keyboard shortcuts

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