Hi! The error reason is self-descriptive, the backends field is an array, not a map.
Chao Zhang https://github.com/tokers On October 24, 2021 at 13:48:23, Rupinder Singh ([email protected]) wrote: Hi, Thanks for responding. APISIXversion is 2.10.0 and the controller version is 1.3.0. I think I'd tried "backends" too. Anyway, I tried creating the ApisixRoute again. This is what I get, the same as I got in earlier tries. error: error validating "httpbin-route.yaml": error validating data: ValidationError(ApisixRoute.spec.http[0].backends): invalid type for org.apache.apisix.v2beta1.ApisixRoute.spec.http.backends: got "map", expected "array"; if you choose to ignore these errors, turn validation off with --validate=false However, I now recall (could reproduce) that with "backend," *initially* Warning: apisix.apache.org/v2beta1 ApisixRoute is deprecated; use apisix.apache.org/v2beta2 ApisixRoute apisixroute.apisix.apache.org/httpserver-route created And that made me change apiversion to apisix.apache.org/v2beta2and try both "backend" and "backends" after deleting previously created resources. This is what I'd got, error: error validating "httpbin-route.yaml": error validating data: ValidationError(ApisixRoute.spec.http[0].backends): invalid type for org.apache.apisix.v2beta2.ApisixRoute.spec.http.backends: got "map", expected "array"; if you choose to ignore these errors, turn validation off with --validate=false error: error validating "httpbin-route.yaml": error validating data: [ValidationError(ApisixRoute.spec.http[0]): unknown field "backend" in org.apache.apisix.v2beta2.ApisixRoute.spec.http, ValidationError(ApisixRoute.spec.http[0]): missing required field "backends" in org.apache.apisix.v2beta2.ApisixRoute.spec.http]; if you choose to ignore these errors, turn validation off with --validate=false regards Rupinder On Sun, Oct 24, 2021 at 8:58 AM Chao Zhang <[email protected]> wrote: > Hi! > > So what’s the version of your apisix-ingress-controller? Since v1.3 we > dropped the support of `backend` field in ApisixRoute, so you should use > backends instead. > > Chao Zhang > https://github.com/tokers > > On October 23, 2021 at 19:07:10, Rupinder Singh ([email protected]) > wrote: > > ---------- Forwarded message --------- > From: Rupinder Singh <[email protected]> > Date: Fri, Oct 22, 2021 at 9:01 PM > Subject: Ingress APISIX install on Minikube > To: <[email protected]> > > > Hi, > > Following > https://apisix.apache.org/docs/ingress-controller/deployments/minikube/ > and > testing with > > https://apisix.apache.org/docs/ingress-controller/practices/proxy-the-httpbin-service/ > , I 'm getting > > Defaulted container "apisix" out of: apisix, wait-etcd (init) > <html> > <head><title>401 Authorization Required</title></head> > <body> > <center><h1>401 Authorization Required</h1></center> > <hr><center>openresty</center> > </body> > </html> > > So, I looked up these discussions > https://github.com/apache/apisix-ingress-controller/issues/554 > https://github.com/apache/apisix-ingress-controller/issues/338 > > So, is the api version and "backend" fied ok? Is it 'backends' ? Request > help. > > regards > Rupinder > >
