Documentation ¶
Index ¶
- type UnikernelRuntime
- func (u *UnikernelRuntime) Attach(req *kubeapi.AttachRequest) (*kubeapi.AttachResponse, error)
- func (h *UnikernelRuntime) ContainerStats(containerID string) (*kubeapi.ContainerStats, error)
- func (u *UnikernelRuntime) ContainerStatus(rawContainerID string) (*kubeapi.ContainerStatus, error)
- func (u *UnikernelRuntime) CreateContainer(podSandboxID string, config *kubeapi.ContainerConfig, ...) (string, error)
- func (u *UnikernelRuntime) Exec(req *kubeapi.ExecRequest) (*kubeapi.ExecResponse, error)
- func (u *UnikernelRuntime) ExecSync(rawContainerID string, cmd []string, timeout time.Duration) (stdout, stderr []byte, err error)
- func (u *UnikernelRuntime) ImageFsInfo() ([]*kubeapi.FilesystemUsage, error)
- func (u *UnikernelRuntime) ImageStatus(image *kubeapi.ImageSpec) (*kubeapi.Image, error)
- func (h *UnikernelRuntime) ListContainerStats(filter *kubeapi.ContainerStatsFilter) ([]*kubeapi.ContainerStats, error)
- func (u *UnikernelRuntime) ListContainers(filter *kubeapi.ContainerFilter) ([]*kubeapi.Container, error)
- func (u *UnikernelRuntime) ListImages(filter *kubeapi.ImageFilter) ([]*kubeapi.Image, error)
- func (u *UnikernelRuntime) ListPodSandbox(filter *kubeapi.PodSandboxFilter) ([]*kubeapi.PodSandbox, error)
- func (u *UnikernelRuntime) PodSandboxStatus(podSandboxID string) (*kubeapi.PodSandboxStatus, error)
- func (u *UnikernelRuntime) PortForward(req *kubeapi.PortForwardRequest) (*kubeapi.PortForwardResponse, error)
- func (u *UnikernelRuntime) PullImage(image *kubeapi.ImageSpec, authConfig *kubeapi.AuthConfig) (string, error)
- func (u *UnikernelRuntime) RemoveContainer(rawContainerID string) error
- func (u *UnikernelRuntime) RemoveImage(image *kubeapi.ImageSpec) error
- func (u *UnikernelRuntime) RemovePodSandbox(podSandboxID string) error
- func (h *UnikernelRuntime) ReopenContainerLog(ContainerID string) error
- func (u *UnikernelRuntime) RunPodSandbox(config *kubeapi.PodSandboxConfig) (string, error)
- func (u *UnikernelRuntime) ServiceName() string
- func (u *UnikernelRuntime) StartContainer(rawContainerID string) error
- func (h *UnikernelRuntime) Status() (*kubeapi.RuntimeStatus, error)
- func (u *UnikernelRuntime) StopContainer(rawContainerID string, timeout int64) error
- func (u *UnikernelRuntime) StopPodSandbox(podSandboxID string) error
- func (h *UnikernelRuntime) UpdateContainerResources(rawContainerID string, config *kubeapi.LinuxContainerResources) error
- func (h *UnikernelRuntime) UpdateRuntimeConfig(runtimeConfig *kubeapi.RuntimeConfig) error
- func (u *UnikernelRuntime) Version(kubeApiVersion string) (*kubeapi.VersionResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type UnikernelRuntime ¶
type UnikernelRuntime struct {
// contains filtered or unexported fields
}
func NewUnikernelRuntimeService ¶
func NewUnikernelRuntimeService(cniNetDir, cniPluginDir, fraktiRoot string, defaultCPU, defaultMem int32, enableLog bool) (*UnikernelRuntime, error)
func (*UnikernelRuntime) Attach ¶
func (u *UnikernelRuntime) Attach(req *kubeapi.AttachRequest) (*kubeapi.AttachResponse, error)
Attach prepares a streaming endpoint to attach to a running container.
func (*UnikernelRuntime) ContainerStats ¶
func (h *UnikernelRuntime) ContainerStats(containerID string) (*kubeapi.ContainerStats, error)
ContainerStats returns stats of the container. If the container does not exist, the call returns an error.
func (*UnikernelRuntime) ContainerStatus ¶
func (u *UnikernelRuntime) ContainerStatus(rawContainerID string) (*kubeapi.ContainerStatus, error)
ContainerStatus returns the container status.
func (*UnikernelRuntime) CreateContainer ¶
func (u *UnikernelRuntime) CreateContainer(podSandboxID string, config *kubeapi.ContainerConfig, sandboxConfig *kubeapi.PodSandboxConfig) (string, error)
CreateContainer creates a new container in specified PodSandbox
func (*UnikernelRuntime) Exec ¶
func (u *UnikernelRuntime) Exec(req *kubeapi.ExecRequest) (*kubeapi.ExecResponse, error)
Exec prepares a streaming endpoint to execute a command in the container.
func (*UnikernelRuntime) ExecSync ¶
func (u *UnikernelRuntime) ExecSync(rawContainerID string, cmd []string, timeout time.Duration) (stdout, stderr []byte, err error)
ExecSync runs a command in a container synchronously.
func (*UnikernelRuntime) ImageFsInfo ¶
func (u *UnikernelRuntime) ImageFsInfo() ([]*kubeapi.FilesystemUsage, error)
ImageFsInfo returns information of the filesystem that is used to store images.
func (*UnikernelRuntime) ImageStatus ¶
ImageStatus returns the status of the image.
func (*UnikernelRuntime) ListContainerStats ¶
func (h *UnikernelRuntime) ListContainerStats(filter *kubeapi.ContainerStatsFilter) ( []*kubeapi.ContainerStats, error)
ListContainerStats returns stats of all running containers.
func (*UnikernelRuntime) ListContainers ¶
func (u *UnikernelRuntime) ListContainers(filter *kubeapi.ContainerFilter) ([]*kubeapi.Container, error)
ListContainers lists all containers by filters.
func (*UnikernelRuntime) ListImages ¶
func (u *UnikernelRuntime) ListImages(filter *kubeapi.ImageFilter) ([]*kubeapi.Image, error)
ListImages lists existing images.
func (*UnikernelRuntime) ListPodSandbox ¶
func (u *UnikernelRuntime) ListPodSandbox(filter *kubeapi.PodSandboxFilter) ([]*kubeapi.PodSandbox, error)
ListPodSandbox returns a list of Sandbox.
func (*UnikernelRuntime) PodSandboxStatus ¶
func (u *UnikernelRuntime) PodSandboxStatus(podSandboxID string) (*kubeapi.PodSandboxStatus, error)
PodSandboxStatus returns the Status of the PodSandbox.
func (*UnikernelRuntime) PortForward ¶
func (u *UnikernelRuntime) PortForward(req *kubeapi.PortForwardRequest) (*kubeapi.PortForwardResponse, error)
PortForward prepares a streaming endpoint to forward ports from a PodSandbox.
func (*UnikernelRuntime) PullImage ¶
func (u *UnikernelRuntime) PullImage(image *kubeapi.ImageSpec, authConfig *kubeapi.AuthConfig) (string, error)
PullImage pulls the image with authentication config.
func (*UnikernelRuntime) RemoveContainer ¶
func (u *UnikernelRuntime) RemoveContainer(rawContainerID string) error
RemoveContainer removes the container. If the container is running, the container should be force removed.
func (*UnikernelRuntime) RemoveImage ¶
func (u *UnikernelRuntime) RemoveImage(image *kubeapi.ImageSpec) error
RemoveImage removes the image.
func (*UnikernelRuntime) RemovePodSandbox ¶
func (u *UnikernelRuntime) RemovePodSandbox(podSandboxID string) error
RemovePodSandbox deletes the sandbox. If there are any running containers in the sandbox, they should be force deleted.
func (*UnikernelRuntime) ReopenContainerLog ¶ added in v1.10.0
func (h *UnikernelRuntime) ReopenContainerLog(ContainerID string) error
ReopenContainerLog asks runtime to reopen the stdout/stderr log file for the container.
func (*UnikernelRuntime) RunPodSandbox ¶
func (u *UnikernelRuntime) RunPodSandbox(config *kubeapi.PodSandboxConfig) (string, error)
RunPodSandbox creates and starts a pod-level sandbox.
func (*UnikernelRuntime) ServiceName ¶
func (u *UnikernelRuntime) ServiceName() string
func (*UnikernelRuntime) StartContainer ¶
func (u *UnikernelRuntime) StartContainer(rawContainerID string) error
StartContainer starts the container.
func (*UnikernelRuntime) Status ¶
func (h *UnikernelRuntime) Status() (*kubeapi.RuntimeStatus, error)
Status returns the status of the runtime.
func (*UnikernelRuntime) StopContainer ¶
func (u *UnikernelRuntime) StopContainer(rawContainerID string, timeout int64) error
StopContainer stops a running container with a grace period (i.e. timeout).
func (*UnikernelRuntime) StopPodSandbox ¶
func (u *UnikernelRuntime) StopPodSandbox(podSandboxID string) error
StopPodSandbox stops the sandbox. If there are any running containers in the sandbox, they should be force terminated.
func (*UnikernelRuntime) UpdateContainerResources ¶
func (h *UnikernelRuntime) UpdateContainerResources( rawContainerID string, config *kubeapi.LinuxContainerResources, ) error
UpdateContainerResources updates the resource constraints for the container.
func (*UnikernelRuntime) UpdateRuntimeConfig ¶
func (h *UnikernelRuntime) UpdateRuntimeConfig(runtimeConfig *kubeapi.RuntimeConfig) error
UpdateRuntimeConfig updates runtime configuration if specified
func (*UnikernelRuntime) Version ¶
func (u *UnikernelRuntime) Version(kubeApiVersion string) (*kubeapi.VersionResponse, error)
Version returns the runtime name, runtime version and runtime API version