container

package
v2.1.1-0...-11cc7cf Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2021 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConstructLogDetails

func ConstructLogDetails(podID string, rawLogs string, container string, logSelector *logs.Selection) *logs.LogDetails

ConstructLogDetails creates a new log details structure for given parameters.

func GetLogDetails

func GetLogDetails(client kubernetes.Interface, namespace, podID string, container string,
	logSelector *logs.Selection, usePreviousLogs bool) (*logs.LogDetails, error)

GetLogDetails returns logs for particular pod and container. When container is null, logs for the first one are returned. Previous indicates to read archived logs created by log rotation or container crash

func GetLogFile

func GetLogFile(client kubernetes.Interface, namespace, podID string, container string, usePreviousLogs bool) (io.ReadCloser, error)

GetLogFile returns a stream to the log file which can be piped directly to the response. This avoids out of memory issues. Previous indicates to read archived logs created by log rotation or container crash

Types

type PodContainerList

type PodContainerList struct {
	Containers []string `json:"containers"`
}

PodContainerList is a list of containers of a pod.

func GetPodContainers

func GetPodContainers(client kubernetes.Interface, namespace, podID string) (*PodContainerList, error)

GetPodContainers returns containers that a pod has.

Jump to

Keyboard shortcuts

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