The canonical location of the Kubernetes API definition.
Go to file
Kubernetes Publisher 839e6c7fb6 Merge pull request #130230 from carlory/cleanup-CSIDriverRegistry
clean up CSIDriverRegistry

Kubernetes-commit: 3fdc11cbe0fcc74cdf55a8c30c9a2e2664acb35f
2025-07-05 01:04:45 +00:00
.github delete all duplicate empty blanks 2019-02-22 09:43:51 +08:00
admission remove import doc comments 2024-12-02 14:43:58 +01:00
admissionregistration generate 2024-11-06 14:21:04 -05:00
apidiscovery remove import doc comments 2024-12-02 14:43:58 +01:00
apiserverinternal/v1alpha1 remove import doc comments 2024-12-02 14:43:58 +01:00
apps generate code 2025-05-23 19:31:03 -04:00
authentication remove import doc comments 2024-12-02 14:43:58 +01:00
authorization remove import doc comments 2024-12-02 14:43:58 +01:00
autoscaling generate code 2025-05-23 19:31:03 -04:00
batch Job: Fix API comments for SuccessCriteriaMet 2025-04-17 00:42:26 +09:00
certificates generate code 2025-01-14 14:18:57 +01:00
coordination generated 2025-03-12 16:59:43 +00:00
core/v1 Fix outdated links in VolumeSource godocs 2025-06-11 14:34:50 +02:00
discovery update generate docs for PreferSameTrafficDistribution 2025-02-11 10:06:25 -05:00
events remove import doc comments 2024-12-02 14:43:58 +01:00
extensions run update-codegen.sh 2025-06-11 20:08:52 +00:00
flowcontrol remove import doc comments 2024-12-02 14:43:58 +01:00
imagepolicy remove import doc comments 2024-12-02 14:43:58 +01:00
networking Fix NetworkPolicy podSelector comments 2025-04-17 22:53:23 +09:00
node remove import doc comments 2024-12-02 14:43:58 +01:00
policy Remove general available feature-gate PDBUnhealthyPodEvictionPolicy 2025-01-07 15:24:16 +08:00
rbac remove import doc comments 2024-12-02 14:43:58 +01:00
resource Adjusting AdminAccess Type for API v1beta1 2025-06-17 06:39:33 +02:00
scheduling remove import doc comments 2024-12-02 14:43:58 +01:00
storage make update 2025-02-18 16:52:16 +08:00
storagemigration/v1alpha1 remove import doc comments 2024-12-02 14:43:58 +01:00
testdata DRA API: remove obsolete types from v1alpha3 2025-05-28 12:03:25 +02:00
CONTRIBUTING.md delete all duplicate empty blanks 2019-02-22 09:43:51 +08:00
LICENSE Add README and LICENSE to staging repos 2017-10-23 16:39:02 +05:30
OWNERS enable dep-approvers for staging go.mod/go.sum 2025-04-24 15:38:41 -07:00
README.md staging: add dummy commit to trigger gomod update (#106794) 2021-12-03 08:59:48 +00:00
SECURITY_CONTACTS Update SECURITY_CONTACTS with current PSC 2019-05-29 15:22:35 +05:30
code-of-conduct.md Add code-of-conduct.md to staging repos 2017-12-20 15:21:56 -05:00
doc.go remove import doc comments 2024-12-02 14:43:58 +01:00
go.mod Merge pull request #130230 from carlory/cleanup-CSIDriverRegistry 2025-07-05 01:04:45 +00:00
go.sum Merge pull request #130230 from carlory/cleanup-CSIDriverRegistry 2025-07-05 01:04:45 +00:00
roundtrip_test.go remove networking v1alpha1 and make update 2025-04-30 09:18:02 +00:00

README.md

api

Schema of the external API types that are served by the Kubernetes API server.

Purpose

This library is the canonical location of the Kubernetes API definition. Most likely interaction with this repository is as a dependency of client-go.

It is published separately to avoid diamond dependency problems for users who depend on more than one of k8s.io/client-go, k8s.io/apimachinery, k8s.io/apiserver...

We recommend using the go types in this repo. You may serialize them directly to JSON.

If you want to store or interact with proto-formatted Kubernetes API objects, we recommend using the "official" serialization stack in k8s.io/apimachinery. Directly serializing these types to proto will not result in data that matches the wire format or is compatible with other kubernetes ecosystem tools. The reason is that the wire format includes a magic prefix and an envelope proto. Please see: https://kubernetes.io/docs/reference/using-api/api-concepts/#protobuf-encoding

For the same reason, we do not recommend embedding these proto objects within your own proto definitions. It is better to store Kubernetes objects as byte arrays, in the wire format, which is self-describing. This permits you to use either JSON or binary (proto) wire formats without code changes. It will be difficult for you to operate on both Custom Resources and built-in types otherwise.

Compatibility

Branches track Kubernetes branches and are compatible with that repo.

Where does it come from?

api is synced from https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/api. Code changes are made in that location, merged into k8s.io/kubernetes and later synced here.

Things you should NOT do

  1. https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/api is synced to k8s.io/api. All changes must be made in the former. The latter is read-only.