ReplicationController

复制控制器代表复制控制器的配置。

apiVersion: v1

import "k8s.io/api/core/v1"

ReplicationController

复制控制器代表复制控制器的配置。


ReplicationControllerSpec

ReplicationControllerSpec 是复制控制器的规范。


ReplicationControllerStatus

ReplicationControllerStatus 表示复制控制器的当前状态。


  • replicas (int32), required

    Replicas 是最近观察到的副本数量。更多信息:https://kubernetes.ac.cn/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller

  • availableReplicas (int32)

    此复制控制器的可用副本(至少就绪 minReadySeconds)的数量。

  • readyReplicas (int32)

    此复制控制器的就绪副本数量。

  • fullyLabeledReplicas (int32)

    具有与复制控制器 Pod 模板的标签匹配的标签的 Pod 的数量。

  • conditions ([]ReplicationControllerCondition)

    Patch 策略:在键 type 上合并

    映射:在合并期间将保留键类型上的唯一值

    表示复制控制器当前状态的最新可用观察结果。

    ReplicationControllerCondition 描述了复制控制器在某个时间点的状态。

    • conditions.status (string), required

      条件的状态,为 True、False 或 Unknown 之一。

    • conditions.type (string), required

      条件类型。

    • conditions.lastTransitionTime (Time)

      条件从一个状态过渡到另一个状态的最后时间。

      Time 是 time.Time 的包装器,支持正确地编组到 YAML 和 JSON。为时间包提供的许多工厂方法提供包装器。

    • conditions.message (string)

      指示过渡细节的人类可读消息。

    • conditions.reason (string)

      条件最后一次过渡的原因。

  • observedGeneration (int64)

    ObservedGeneration 反映了最近观察到的复制控制器的生成代数。

ReplicationControllerList

ReplicationControllerList 是复制控制器的集合。


操作


get 读取指定的复制控制器

HTTP 请求

GET /api/v1/namespaces/{namespace}/replicationcontrollers/{name}

Parameters

  • name (在路径中): string, 必需

    复制控制器的名称

  • namespace (在路径中): string, 必需

    命名空间

  • pretty (在查询中): string

    pretty

响应

200 (ReplicationController): 确定

401: 未授权

get 读取指定复制控制器的状态

HTTP 请求

GET /api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status

Parameters

  • name (在路径中): string, 必需

    复制控制器的名称

  • namespace (在路径中): string, 必需

    命名空间

  • pretty (在查询中): string

    pretty

响应

200 (ReplicationController): 确定

401: 未授权

list 列出或监视复制控制器类型的对象

HTTP 请求

GET /api/v1/namespaces/{namespace}/replicationcontrollers

Parameters

响应

200 (ReplicationControllerList): 确定

401: 未授权

list 列出或监视复制控制器类型的对象

HTTP 请求

GET /api/v1/replicationcontrollers

Parameters

响应

200 (ReplicationControllerList): 确定

401: 未授权

create 创建复制控制器

HTTP 请求

POST /api/v1/namespaces/{namespace}/replicationcontrollers

Parameters

响应

200 (ReplicationController): 确定

201 (ReplicationController): 已创建

202 (ReplicationController): 已接受

401: 未授权

update 替换指定的复制控制器

HTTP 请求

PUT /api/v1/namespaces/{namespace}/replicationcontrollers/{name}

Parameters

响应

200 (ReplicationController): 确定

201 (ReplicationController): 已创建

401: 未授权

update 替换指定复制控制器的状态

HTTP 请求

PUT /api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status

Parameters

响应

200 (ReplicationController): 确定

201 (ReplicationController): 已创建

401: 未授权

patch 部分更新指定的复制控制器

HTTP 请求

PATCH /api/v1/namespaces/{namespace}/replicationcontrollers/{name}

Parameters

  • name (在路径中): string, 必需

    复制控制器的名称

  • namespace (在路径中): string, 必需

    命名空间

  • body: Patch, 必需

  • dryRun (在查询中): string

    dryRun

  • fieldManager (在查询中): string

    fieldManager

  • fieldValidation (在查询中): string

    fieldValidation

  • force (in query): boolean

    force

  • pretty (在查询中): string

    pretty

响应

200 (ReplicationController): 确定

201 (ReplicationController): 已创建

401: 未授权

patch 部分更新指定复制控制器的状态

HTTP 请求

PATCH /api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status

Parameters

  • name (在路径中): string, 必需

    复制控制器的名称

  • namespace (在路径中): string, 必需

    命名空间

  • body: Patch, 必需

  • dryRun (在查询中): string

    dryRun

  • fieldManager (在查询中): string

    fieldManager

  • fieldValidation (在查询中): string

    fieldValidation

  • force (in query): boolean

    force

  • pretty (在查询中): string

    pretty

响应

200 (ReplicationController): 确定

201 (ReplicationController): 已创建

401: 未授权

delete 删除复制控制器

HTTP 请求

DELETE /api/v1/namespaces/{namespace}/replicationcontrollers/{name}

Parameters

响应

200 (Status): 确定

202 (Status): 已接受

401: 未授权

deletecollection 删除复制控制器集合

HTTP 请求

DELETE /api/v1/namespaces/{namespace}/replicationcontrollers

Parameters

响应

200 (Status): 确定

401: 未授权

本页面是自动生成的。

如果您打算报告此页面的问题,请在您的问题描述中提及该页面是自动生成的。修复可能需要在 Kubernetes 项目的其他地方进行。

上次修改时间:2025 年 4 月 9 日下午 6:36 PST:更新 v1.32 的 API 参考文档 (a3b579d035)