k8s

package
v0.0.0-...-353f5b5 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDeployment

func NewDeployment(name, namespace string, opts DeploymentOpts) (*v1.Deployment, error)

func NewJob

func NewJob(name, namespace string, opts JobOpts) *v1.Job

func NewServiceClusterIP

func NewServiceClusterIP(name, namespace string, ports []int, labels, selectorLabels map[string]string) *v1.Service

NewServiceClusterIP create a Service instance of a ClusterIP type using the given labels and selectors.

Types

type DeploymentOpts

type DeploymentOpts struct {
	Image         string
	Labels        map[string]string
	RestartPolicy v13.RestartPolicy
	Command       []string
	Args          []string
	EnvVars       []v13.EnvVar
}

type JobOpts

type JobOpts struct {
	Image        string
	BackoffLimit int
	Restart      core.RestartPolicy
	Env          map[string]string
	Labels       map[string]string
	Args         []string
}

Jump to

Keyboard shortcuts

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