utils

package
v1.4.10-beta.0 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2017 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FailedContainers

func FailedContainers(pod *api.Pod) map[string]ContainerFailures

FailedContainers inspects all containers in a pod and returns failure information for containers that have failed or been restarted. A map is returned where the key is the containerID and the value is a struct containing the restart and failure information

func MakeTempDirOrDie

func MakeTempDirOrDie(prefix string, baseDir string) string

func PodNotReady

func PodNotReady(p *api.Pod) (bool, error)

PodNotReady checks whether pod p's has a ready condition of status false.

func PodReady

func PodReady(pod *api.Pod) bool

podReady returns whether pod has a condition of Ready with a status of true. TODO: should be replaced with api.IsPodReady

func PodRunningReady

func PodRunningReady(p *api.Pod) (bool, error)

PodRunningReady checks whether pod p's phase is running and it has a ready condition of status true.

func PodRunningReadyOrSucceeded

func PodRunningReadyOrSucceeded(p *api.Pod) (bool, error)

func TerminatedContainers

func TerminatedContainers(pod *api.Pod) map[string]string

TerminatedContainers inspects all containers in a pod and returns a map of "container name: termination reason", for all currently terminated containers.

Types

type ContainerFailures

type ContainerFailures struct {
	Restarts int
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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