⚠️ 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:
- Slack: #sig-node (on https://kubernetes.slack.com -- get an invite at slack.kubernetes.io)
- Mailing List: https://groups.google.com/a/kubernetes.io/g/sig-node
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.33.0 v1.34.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
- Removed the gogo dependency
- Added
debug_redactflags to the following fields ofAuthConfig: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
- Added clarifying comment to the [host_port] field of [PortMapping].
-
[KEP-4639] Graduate image volume sources to beta
- Added
image_sub_pathto the typeMountto represent the subpath inside the image to mount.
- Added
-
[FG:InPlacePodVerticalScaling] Add UpdatePodSandboxResources CRI method
- New method
UpdatePodSandboxResourcesto synchronously updates the PodSandboxConfig with the pod-level resource configuration. - Added the
UpdatePodSandboxResourcesRequesttype to pass as an argument toUpdatePodSandboxResources. - Added the
UpdatePodSandboxResourcesResponseempty type to return from theUpdatePodSandboxResources.
- New method
-
Withdraw alpha support for HostNetwork containers on Windows
- Added clarifying comment on the
networkfield of the typeWindowsNamespaceOptionas HostNetwork containers are not supported.
- Added clarifying comment on the
-
Surface Pressure Stall Information (PSI) metrics
- Added
iofield to the typesLinuxPodSandboxStatsandContainerStatsto represent the IO usage. - Added
psifield to the typeCpuUsage. - Added types
IoUsage,PsiStats, andPsiDatato represent IO usage and PSI statistics.
- Added
-
KEP 4960: Container Stop Signals
- Added the field
stop_signalto theContainerConfigtype. - Added the enum
Signallisting all possible stop signals.
- Added the field
git diff v1.31.0 v1.32.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
- CRI: Add field to support CPU affinity on Windows
- CRI field
affinity_cpustoWindowsContainerResourcesstruct 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.
- CRI field
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
- Added
featuresfield to the typeStatusResponsefor the runtime to kubelet handshake on what features are supported
- Added
-
KEP-3619: Fine-grained SupplementalGroups control
- Added
supplemental_groups_policyfield to typesLinuxContainerSecurityContextandLinuxSandboxSecurityContext - Added
userfield to the typeContainerStatusto represent actual user for the container
- Added
-
[KEP-4639] Add OCI VolumeSource CRI API
- Added
imagefield to the typeMountto represent the OCI VolumeSource
- Added
git diff v1.29.0 v1.30.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
-
Recursive Read-only (RRO) mounts
- Added RuntimeHandler and RuntimeHandlerFeatures type
- Added
recursive_read_onlyfield to typeMount - Added
runtime_handlersfield to typeStatusResponse
-
Add user_namespaces field to RuntimeHandlerFeatures
- Added
user_namespacesfield to typeRuntimeHandlerFeatures
- Added
-
Add image_id to CRI Container message
- Added
image_idfield to typeContainer
- Added
-
Add image_id to CRI ContainerStatus message
- Added
image_idfield to typeContainerStatus
- Added
git 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
- Added
runtime_handlerfield to typeImageSpec
- Added
-
Add container filesystem to the ImageFsInfoResponse
- Added
container_filesystemsfield to typeImageFsInfoResponse
- Added
git 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
- Fixed comment lines about PROPAGATION_PRIVATE
-
Add user specified image to CRI ContainerConfig
- Added the
user_specified_imagefield to typeImageSpec
- Added the
-
kubelet: get cgroup driver config from CRI
- Added rpc for querying runtime configuration
- Added cavieats about cgroup driver field
-
Add swap to stats to Summary API and Prometheus endpoints (/stats/summary and /metrics/resource)
- Added
SwapUsagetype - Added
SwapUsagefield toContainerStatstype
- Added
-
Expose commit memory used in WindowsMemoryUsage struct
- Added the
commit_memory_bytesfield to typeWindowsMemoryUsage
- Added the
git 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
- New type
CDIDevicewas introduced and added to container config
- New type
-
- Added new fields to the type
Mountexpressing runtime UID/GID mappings for the mount.
- Added new fields to the type
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
- Added fields to the type
WindowsPodSandboxStatsexpressing stats required to be collected from windows pods.
- Added fields to the type
-
- New type
WindowsNamespaceOptionintroduced - The type
WindowsSandboxSecurityContexthas a new fieldnamespace_optionsof typeWindowsNamespaceOption
- New type
-
- Clarified the expected behavior of
SupplementalGroupsfield ofPodSecurityContext
- Clarified the expected behavior of
-
- The type
ContainerEventResponseupdated: the fieldpod_sandbox_metadataremoved and fieldspod_sandbox_statusandcontainers_statusesadded. - The type
PodSandboxStatusResponsehas a new fieldscontainers_statusesandtimestamp
- The type
git 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
- The new type
UserNamespaceintroduced to represent user namespaces id mapping - The type
NamespaceOptionhas a new fielduserns_optionsof typeUserNamespace
- The new type
-
- The new method
CheckpointContainerintroduced with the corresponding request and response types
- The new method
-
Update CRI API to support Evented PLEG
- The new streaming method
GetContainerEventsis introduced with the corresponding request and response types
- The new streaming method
-
CRI changes to support in-place pod resize
- The new type
ContainerResourcesis introduced - The type
ContainerStatushas a new fieldresourcesof typeContainerResources - The semantic of
UpdateContainerResourcesupdated. The method must be implemented as synchronous and return error on failure
- The new type
git 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
- The type
Capabilityhas a new string fieldadd_ambient_capabilities
- The type
-
CRI-API - Add rootfs size to WindowsContainerResources
- The type
WindowsContainerResourceshas a new int64 fieldrootfs_size_in_bytes
- The type
git 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
- New functions
PodSandboxStats,ListPodSandboxStatswith the corresponding types of request and response objects are introduced
- New functions
-
pass sandbox resource requirements over CRI
- New fields on
LinuxPodSandboxConfig:overheadandresourcesof typeLinuxContainerResources.
- New fields on
-
prevents garbage collection from removing pinned images
- The type
Imagehas a new boolean fieldpinned
- The type
git diff v1.21.0 v1.22.0 -- staging/src/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto
-
PodSandboxConfighaswindowsfield of typeWindowsPodSandboxConfig- New type
WindowsPodSandboxConfigintroduced - New type
WindowsSandboxSecurityContextintroduced - The type
WindowsContainerSecurityContexthas a newhost_processboolean field
-
Feature: add unified on CRI to support cgroup v2
- The type
LinuxContainerResourceshas a new fieldunifiedwhich is a map of strings
- The type
-
- The type
LinuxContainerResourceshas a newmemory_swap_limit_in_bytesint64 field
- The type
git 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
- CRI v1 introduced