[英]Kubernetes error json: cannot unmarshal string into Go value of type map[string]interface {}
I am trying to execute this rolling update example in v1.6.2 cluster. 我正在尝试在v1.6.2集群中执行此滚动更新示例。 my kubectl command giving this error message.
我的kubectl命令给出了这个错误信息。
Error from server: json: cannot unmarshal string into Go value of type map[string]interface {}
Here is the YMAL file from this page: https://www.mirantis.com/blog/scaling-kubernetes-daemonsets/ 这是此页面上的YMAL文件: https : //www.mirantis.com/blog/scaling-kubernetes-daemonsets/
apiVersion: extensions/v1beta1
kind: DaemonSet
metadata:
name: frontend
spec:
updateStrategy: RollingUpdate
maxUnavailable: 1
minReadySeconds: 0
template:
metadata:
labels:
app: frontend-webserver
spec:
nodeSelector:
app: frontend-node
containers:
- name: webserver
image: nginx
ports:
- containerPort: 80
How to resolve this error? 如何解决这个错误?
Thanks SR 谢谢SR
The updateStrategy
appears to be incorrect: updateStrategy
似乎不正确:
apiVersion: extensions/v1beta1
kind: DaemonSet
metadata:
name: frontend
spec:
updateStrategy:
type: RollingUpdate
maxUnavailable: 1
template:
metadata:
labels:
app: frontend-webserver
spec:
nodeSelector:
app: frontend-node
containers:
- name: webserver
image: nginx
ports:
- containerPort: 80
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.