Documentation
¶
Overview ¶
Package kuberuntime contains an implementation of kubecontainer.Runtime using the interface in pkg/kubelet/v1.
Index ¶
- Variables
- func BuildContainerLogsDirectory(podNamespace, podName string, podUID types.UID, containerName string) string
- func BuildPodLogsDirectory(podNamespace, podName string, podUID types.UID) string
- func GetHugepageLimitsFromResources(resources v1.ResourceRequirements) []*runtimeapi.HugepageLimit
- type KubeGenericRuntime
- type LegacyLogProvider
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrCreateContainerConfig - failed to create container config ErrCreateContainerConfig = errors.New("CreateContainerConfigError") // ErrPreCreateHook - failed to execute PreCreateHook ErrPreCreateHook = errors.New("PreCreateHookError") // ErrCreateContainer - failed to create container ErrCreateContainer = errors.New("CreateContainerError") // ErrPreStartHook - failed to execute PreStartHook ErrPreStartHook = errors.New("PreStartHookError") // ErrPostStartHook - failed to execute PostStartHook ErrPostStartHook = errors.New("PostStartHookError") )
View Source
var ( // ErrVersionNotSupported is returned when the api version of runtime interface is not supported ErrVersionNotSupported = errors.New("runtime api version is not supported") )
Functions ¶
func BuildContainerLogsDirectory ¶ added in v1.10.0
func BuildContainerLogsDirectory(podNamespace, podName string, podUID types.UID, containerName string) string
BuildContainerLogsDirectory builds absolute log directory path for a container in pod.
func BuildPodLogsDirectory ¶ added in v1.14.0
BuildPodLogsDirectory builds absolute log directory path for a pod sandbox.
func GetHugepageLimitsFromResources ¶ added in v1.18.0
func GetHugepageLimitsFromResources(resources v1.ResourceRequirements) []*runtimeapi.HugepageLimit
GetHugepageLimitsFromResources returns limits of each hugepages from resources.
Types ¶
type KubeGenericRuntime ¶ added in v1.5.0
type KubeGenericRuntime interface { kubecontainer.Runtime kubecontainer.StreamingRuntime kubecontainer.CommandRunner }
KubeGenericRuntime is a interface contains interfaces for container runtime and command.
func NewKubeGenericRuntimeManager ¶
func NewKubeGenericRuntimeManager( recorder record.EventRecorder, livenessManager proberesults.Manager, readinessManager proberesults.Manager, startupManager proberesults.Manager, seccompProfileRoot string, machineInfo *cadvisorapi.MachineInfo, podStateProvider podStateProvider, osInterface kubecontainer.OSInterface, runtimeHelper kubecontainer.RuntimeHelper, httpClient types.HTTPGetter, imageBackOff *flowcontrol.Backoff, serializeImagePulls bool, imagePullQPS float32, imagePullBurst int, imageCredentialProviderConfigFile string, imageCredentialProviderBinDir string, cpuCFSQuota bool, cpuCFSQuotaPeriod metav1.Duration, runtimeService internalapi.RuntimeService, imageService internalapi.ImageManagerService, internalLifecycle cm.InternalContainerLifecycle, legacyLogProvider LegacyLogProvider, logManager logs.ContainerLogManager, runtimeClassManager *runtimeclass.Manager, seccompDefault bool, memorySwapBehavior string, ) (KubeGenericRuntime, error)
NewKubeGenericRuntimeManager creates a new kubeGenericRuntimeManager
type LegacyLogProvider ¶ added in v1.9.0
type LegacyLogProvider interface { // GetContainerLogTail gets the last few lines of the logs for a specific container. GetContainerLogTail(uid kubetypes.UID, name, namespace string, containerID kubecontainer.ContainerID) (string, error) }
LegacyLogProvider gives the ability to use unsupported docker log drivers (e.g. journald)
Source Files
¶
- convert.go
- doc.go
- fake_kuberuntime_manager.go
- helpers.go
- helpers_linux.go
- instrumented_services.go
- kuberuntime_container.go
- kuberuntime_container_linux.go
- kuberuntime_gc.go
- kuberuntime_image.go
- kuberuntime_logs.go
- kuberuntime_manager.go
- kuberuntime_sandbox.go
- labels.go
- legacy.go
- security_context.go
- security_context_others.go
Click to show internal directories.
Click to hide internal directories.