cci
创建工作负载
更新时间:2021/02/10 GMT+08:00
yaml文件创建
- 添加annotations
创建弹性至CCI的负载时需要在pod的annotations中添加如下字段:
virtual-kubelet.io/burst-to-cci: "true"
其中,value值支持以下选项:
- true或者auto:CCE资源用完时自动弹性至CCI。
- enforce:强制调度至CCI。
- off:不调度至CCI。
- 示例模板
apiVersion: apps/v1 kind: Deployment metadata: name: test-vk labels: {} spec: replicas: 20 selector: matchLabels: app: test-vk template: metadata: annotations: virtual-kubelet.io/burst-to-cci: 'true' labels: app: test-vk spec: containers: - name: container-0 image: centos:latest resources: limits: cpu: 500m memory: 1024Mi requests: cpu: 500m memory: 1024Mi command: - /bin/bash - '-c' - sleep 10000 dnsPolicy: Default
image需填写华为云SWR中的镜像地址,包括我的镜像和镜像中心中的镜像资源。
父主题: 华为云CCE弹性至CCI
