⚠️ This is an automatically published staged repository for Kubernetes.
Contributions, including issues and pull requests, should be made to the main Kubernetes repository: https://github.com/kubernetes/kubernetes.
This repository is read-only for importing, and not used for direct contributions.
See CONTRIBUTING.md for more details.
This repository contains the definitions for the Container Runtime Interface (CRI). CRI is a plugin interface which enables kubelet to use a wide variety of container runtimes, without the need to recompile. CRI consists of a protocol buffers and gRPC API. Read more about CRI API at kubernetes docs.
The repository kubernetes/cri-api is a mirror of https://github.com/kubernetes/kubernetes/tree/master/staging/src/k8s.io/cri-api. Please do not file issues or submit PRs against the kubernetes/cri-api repository as it is readonly, all development is done in kubernetes/kubernetes.
The CRI API is defined in kubernetes/kubernetes repository and is only intended to be used for kubelet to container runtime interactions, or for node-level troubleshooting using a tool such as crictl. It is not a common purpose container runtime API for general use, and is intended to be Kubernetes-centric. We try to avoid it, but there may be logic within a container runtime that optimizes for the order or specific parameters of call(s) that the kubelet makes.
Please read about:
Learn how to engage with the Kubernetes community on the community page.
You can reach the maintainers of this repository at:
Issues can be filed at https://github.com/kubernetes/kubernetes/issues. See CONTRIBUTING.md.
Participation in the Kubernetes community is governed by the Kubernetes Code of Conduct.
See CONTRIBUTING.md for more information. Please note that kubernetes/cri-api is a readonly mirror repository, all development is done at kubernetes/kubernetes.
Here is the change history of the Container Runtime Interface protocol. The change history is maintained manually:
git diff v1.35.0 v1.36.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
[KEP-5825] cri-api: Add streaming RPCs for CRI list operations
StreamPodSandboxes, StreamContainers, StreamContainerStats, StreamPodSandboxStats, StreamPodSandboxMetrics, and StreamImages.Stricter image reference meaning
PullImageResponse.image_ref MUST match Image.id, Container.image_id, and ContainerStatus.image_id.[KEP-5365] Implement Image Volume with Digest
image_ref field to the type ImageSpec.Update OCI image volume type description to remove "noexec" attribute
Mount type.Add alpha-2 stage implementation for UserNamespacesHostNetworkSupport
user_namespaces_host_network field to the type RuntimeFeatures.Clarify RemoveImage CRI API call
RemoveImage and ImageFsInfo explaining behavior when an image is referenced by multiple tags.git diff v1.34.0 1.35.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
No changes
git diff v1.33.0 v1.34.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
debug_redact flags to the following fields of AuthConfig: password, auth, identity_token, registry_token.git diff v1.32.0 v1.33.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
Clarify the behavior when the host_port value is set to 0 in CRI
[KEP-4639] Graduate image volume sources to beta
image_sub_path to the type Mount to represent the subpath inside the image to mount.[FG:InPlacePodVerticalScaling] Add UpdatePodSandboxResources CRI method
UpdatePodSandboxResources to synchronously updates the PodSandboxConfig with the pod-level resource configuration.UpdatePodSandboxResourcesRequest type to pass as an argument to UpdatePodSandboxResources.UpdatePodSandboxResourcesResponse empty type to return from the UpdatePodSandboxResources.Withdraw alpha support for HostNetwork containers on Windows
network field of the type WindowsNamespaceOption as HostNetwork containers are not supported.Surface Pressure Stall Information (PSI) metrics
io field to the types LinuxPodSandboxStats and ContainerStats to represent the IO usage.psi field to the type CpuUsage.IoUsage, PsiStats, and PsiData to represent IO usage and PSI statistics.KEP 4960: Container Stop Signals
stop_signal to the ContainerConfig type.Signal listing all possible stop signals.git diff v1.31.0 v1.32.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
affinity_cpus to WindowsContainerResources struct to support CPU affinity on Windows. This field will be used by Windows CPU manager to set the logical processors to affinitize for a particular container down to containerd/hcsshim.git diff v1.30.0 v1.31.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
KEP-3619: Add NodeStatus.Features.SupplementalGroupsPolicy API and e2e
features field to the type StatusResponse for the runtime to kubelet handshake on what features are supportedKEP-3619: Fine-grained SupplementalGroups control
supplemental_groups_policy field to types LinuxContainerSecurityContext and LinuxSandboxSecurityContextuser field to the type ContainerStatus to represent actual user for the container[KEP-4639] Add OCI VolumeSource CRI API
image field to the type Mount to represent the OCI VolumeSourcegit diff v1.29.0 v1.30.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
Recursive Read-only (RRO) mounts
recursive_read_only field to type Mountruntime_handlers field to type StatusResponseAdd user_namespaces field to RuntimeHandlerFeatures
user_namespaces field to type RuntimeHandlerFeaturesAdd image_id to CRI Container message
image_id field to type ContainerAdd image_id to CRI ContainerStatus message
image_id field to type ContainerStatusgit diff v1.28.0 v1.29.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
Add runtime handler field to ImageSpec struct
runtime_handler field to type ImageSpecAdd container filesystem to the ImageFsInfoResponse
container_filesystems field to type ImageFsInfoResponsegit diff v1.27.0 v1.28.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
cri-api: fix comment lines about PROPAGATION_PRIVATE
Add user specified image to CRI ContainerConfig
user_specified_image field to type ImageSpeckubelet: get cgroup driver config from CRI
Add swap to stats to Summary API and Prometheus endpoints (/stats/summary and /metrics/resource)
SwapUsage typeSwapUsage field to ContainerStats typeExpose commit memory used in WindowsMemoryUsage struct
commit_memory_bytes field to type WindowsMemoryUsagegit diff v1.26.0 v1.27.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
CRI: Add CDI device info for containers
CDIDevice was introduced and added to container configMount expressing runtime UID/GID mappings for the mount.git diff v1.25.0 v1.26.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
CRI: Add Windows Podsandbox Stats
WindowsPodSandboxStats expressing stats required to be collected from windows pods.WindowsNamespaceOption introducedWindowsSandboxSecurityContext has a new field namespace_options of type WindowsNamespaceOptionSupplementalGroups field of PodSecurityContextContainerEventResponse updated: the field pod_sandbox_metadata removed and fields pod_sandbox_status and containers_statuses added.PodSandboxStatusResponse has a new fields containers_statuses and timestampgit diff v1.24.0 v1.25.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
kubelet: add CRI definitions for user namespaces
UserNamespace introduced to represent user namespaces id mappingNamespaceOption has a new field userns_options of type UserNamespaceCheckpointContainer introduced with the corresponding request and response typesUpdate CRI API to support Evented PLEG
GetContainerEvents is introduced with the corresponding request and response typesCRI changes to support in-place pod resize
ContainerResources is introducedContainerStatus has a new field resources of type ContainerResourcesUpdateContainerResources updated. The method must be implemented as synchronous and return error on failuregit diff v1.23.0 v1.24.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
Update CRI-API Capabilities to include a field that allows us to set ambient capabilities
Capability has a new string field add_ambient_capabilitiesCRI-API - Add rootfs size to WindowsContainerResources
WindowsContainerResources has a new int64 field rootfs_size_in_bytesgit diff v1.22.0 v1.23.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
CRI: add fields for pod level stats to satisfy the /stats/summary API
PodSandboxStats, ListPodSandboxStats with the corresponding types of request and response objects are introducedpass sandbox resource requirements over CRI
LinuxPodSandboxConfig: overhead and resources of type LinuxContainerResources.prevents garbage collection from removing pinned images
Image has a new boolean field pinnedgit diff v1.21.0 v1.22.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
PodSandboxConfig has windows field of type WindowsPodSandboxConfigWindowsPodSandboxConfig introducedWindowsSandboxSecurityContext introducedWindowsContainerSecurityContext has a new host_process boolean fieldFeature: add unified on CRI to support cgroup v2
LinuxContainerResources has a new field unified which is a map of stringsLinuxContainerResources has a new memory_swap_limit_in_bytes int64 fieldgit diff v1.20.0 v1.21.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
No changes
git diff v1.19.0 v1.20.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto