Kubernetes 的官方 C 客户端库
This is the official Kubernetes client library for the C programming language.
…If you want to install the C client using vcpkg, please refer to vcpkg.md
If you want to install the C client using conan, please refer to conan.md
cd ${CLIENT_REPO_ROOT}/examples/list_pod
make./list_pod_binlist all pods:
…list all pods in cluster:
…If you want to send an integer or boolean parameter to the API server, you will see that the data type in API function is int *, e.g.
…For example we can send timeoutSeconds and watch using the following usage:
…Setting the parameter to NULL means not to send the parameter to the API Server, and the API Server will use the default value for this parameter.
If you want to implement a client for aggregated APIs (such as the metrics server API apis/metrics.k8s.io ) or CRD-based APIs, use the generic client. See example.
If the C client library is used in multi-threaded program, the following 2 actions are required:
After the program starts up, main thread must call the function apiClient_setupGlobalEnv() before any worker thread is created.
If the C client is no longer used, main thread must call the function apiClient_unsetupGlobalEnv() after all worker threads end.
Refer to the example for detail.
All APIs and Models' documentation can be found at the Generated client's README file
See versioning-and-compatibility.md
Learn how to engage with the Kubernetes community on the community page.
You can reach the maintainers of this project at:
Participation in the Kubernetes community is governed by the Kubernetes Code of Conduct.
暂无开放 Issues,或尚未同步最近议题。