k8sjob

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2021 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ENABLE_SPECIFIED_K8S_NAMESPACE = "ENABLE_SPECIFIED_K8S_NAMESPACE"
)
View Source
const (
	EnvRetainNamespace = "RETAIN_NAMESPACE"
)

Variables

View Source
var Kind = types.Kind("k8sjob")

Functions

This section is empty.

Types

type K8sJob

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

func New

func New(name types.Name, clusterName string, cluster apistructs.ClusterInfo) (*K8sJob, error)

func (*K8sJob) BatchDelete

func (k *K8sJob) BatchDelete(ctx context.Context, tasks []*spec.PipelineTask) (data interface{}, err error)

func (*K8sJob) Create

func (k *K8sJob) Create(ctx context.Context, action *spec.PipelineTask) (data interface{}, err error)

func (*K8sJob) CreatePVCIfNotExists

func (k *K8sJob) CreatePVCIfNotExists(ctx context.Context, pvc *corev1.PersistentVolumeClaim) error

func (*K8sJob) Inspect

func (k *K8sJob) Inspect(ctx context.Context, task *spec.PipelineTask) (apistructs.TaskInspect, error)

Inspect use kubectl describe pod information, return latest pod description for current job

func (*K8sJob) JobVolumeCreate

func (k *K8sJob) JobVolumeCreate(ctx context.Context, jobVolume apistructs.JobVolume) (string, error)

func (*K8sJob) Kind

func (k *K8sJob) Kind() types.Kind

func (*K8sJob) Name

func (k *K8sJob) Name() types.Name

func (*K8sJob) Remove

func (k *K8sJob) Remove(ctx context.Context, task *spec.PipelineTask) (data interface{}, err error)

func (*K8sJob) Status

func (k *K8sJob) Status(ctx context.Context, action *spec.PipelineTask) (desc apistructs.StatusDesc, err error)

type Message

type Message struct {
	Timestamp int64
	Reason    string
	Message   string
	Comment   string
}

Message Event message

type MessageList

type MessageList []Message

MessageList 事件消息列表

func (MessageList) Len

func (em MessageList) Len() int

func (MessageList) Less

func (em MessageList) Less(i, j int) bool

func (MessageList) Swap

func (em MessageList) Swap(i, j int)

Jump to

Keyboard shortcuts

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