Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/visual-studio-code/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Kubernetes 使用istioctl传递loadBalancerSourceRanges参数_Kubernetes_Kubernetes Helm_Amazon Elb_Istio - Fatal编程技术网

Kubernetes 使用istioctl传递loadBalancerSourceRanges参数

Kubernetes 使用istioctl传递loadBalancerSourceRanges参数,kubernetes,kubernetes-helm,amazon-elb,istio,Kubernetes,Kubernetes Helm,Amazon Elb,Istio,我想部署Istio的演示应用程序,并使用以下命令将源范围传递给负载平衡器: istioctl manifest apply --set profile=demo --set values.gateways.istio-ingressgateway.loadBalancerSourceRanges={"x.x.x.x/x"} 不幸的是,我得到了以下错误: Error: failed to apply manifests: validation errors (use --force to ove

我想部署Istio的演示应用程序,并使用以下命令将源范围传递给负载平衡器:

istioctl manifest apply --set profile=demo --set values.gateways.istio-ingressgateway.loadBalancerSourceRanges={"x.x.x.x/x"}
不幸的是,我得到了以下错误:

Error: failed to apply manifests: validation errors (use --force to override):
json: cannot unmarshal string into Go value of type []json.RawMessage

如何以正确的格式传递参数(ZSH作为shell)?

您可以直接指定数组的索引,并且在ZSH中必须转义方括号

工作命令现在如下所示:

istioctl manifest apply --set profile=demo --set values.gateways.istio-ingressgateway.loadBalancerSourceRanges\[0\]=x.x.x.x/x

您好,您使用的是什么版本的istio?我正在使用istio 1.5.2