检测到您已登录华为云国际站账号,为了您更好的体验,建议您访问国际站服务网站 https://www.huaweicloud.com/intl/zh-cn
不再显示此消息
服务器接收到该对象后,会将其表示的操作应用于目标JSON对象。 Merge Patch, Content-Type: application/merge-patch+json 在RFC7386协议的定义中,Merge Patch必须包含对一个资源对象的部分描述,即为JSON对象。
selector={"matchLabels": {"app": app}}, template=client.V1PodTemplateSpec( metadata=client.V1ObjectMeta(labels={"
kind": "Deployment", "metadata": { "name": "nginx" }, "spec": { "replicas": 2, "selector": { "app
$ kubectl get pod -L app,env -n $namespace_name NAME READY STATUS RESTARTS AGE APP ENV nginx 1/1 Running
GET /apis/apps/v1/deployments CCI:namespaceSubResource:List √ √ 替换Deployment PUT /apis/apps/v1/namespaces/{namespace}/deployments/{name} CCI
app: redis template: metadata: labels: app: redis annotations: cci.io/image-snapshot-auto-match: "true"
$ kubectl delete po -l app=nginx -n $namespace_name pod "nginx" deleted 父主题: Pod
CCI spec: replicas: 2 selector: matchLabels: app: test template: metadata: labels: app: test spec:
创建独占带宽类型的Deployment,无需指定带宽ID,示例如下: apiVersion: apps/v1 kind: Deployment metadata: annotations: deployment.kubernetes.io/revision
kubectl apply -f profile.yaml 创建无状态负载,使用selector方式选择含有“app:nginx”的pod,关联上文创建的profile。
YAML支持三种数据结构 对象:键值对的集合,又称为映射(mapping)/ 哈希(hashes)/ 字典(dictionary)。 数组:一组按次序排列的值,又称为序列(sequence) / 列表(list)。
服务器接收到该对象后,会将其表示的操作应用于目标JSON对象。 Merge Patch, Content-Type: application/merge-patch+json 在RFC7386协议的定义中,Merge Patch必须包含对一个资源对象的部分描述,即为JSON对象。
apiVersion: apps/v1 kind: Deployment metadata: name: nginx spec: replicas: 3 selector: matchLabels: app: nginx template:
apiVersion: apps/v1 kind: Deployment metadata: name: nginx spec: replicas: 1 selector: matchLabels: app: nginx strategy:
api) throws ApiException { String app = APP; String cpu = "500m"; String memory = "1024Mi"; String containerName
Applied only if Name is not specified.
请求示例: Content-Type: application/merge-patch+json { "metadata": { "labels": { "app": "test" } } } 响应消息 响应参数
spec: replicas: 2 selector: matchLabels: app: cci-downwardapi-test template: metadata: labels: app: cci-downwardapi-test
Applied only if Name is not specified.
Applied only if Name is not specified.