Error when adding WMS services

360 views
Skip to first unread message

Darwin Denis Quispe Llancacuro

unread,
Sep 26, 2017, 1:45:58 PM9/26/17
to TerriaJS
Hi,

I'm testing Terria Map but I'm getting errors when adding WMS services to the map, for example I get this message "Request has failed. Status Code: 500" when I try to add the "Broadband ADSL Quality" layer included as a demo. I see that the same errors occurs in the demo published at http://map.terria.io/.

I hope you could help me, thanks in advance.

Kind regards.

Kevin Ring

unread,
Oct 3, 2017, 1:08:24 AM10/3/17
to TerriaJS
Hi,

The problem appears to be that the WMS server is using an SSL certificate that can't be verified by the terriajs-server proxy.  We may be able to fix that by updating the certificate authority list on the map.terria.io server.  Are you seeing the same problem with your own WMS layers?  The more common problem when using your own layers is that they don't support CORS, and they haven't been added to the proxy white list, so web browser security prevents TerriaJS prevents TerriaJS from accessing them.  You can fix this by adding your domains to the proxy whitelist.  See this page in the docs for more information on that:

Kevin

Darwin Denis Quispe Llancacuro

unread,
Oct 11, 2017, 5:35:47 PM10/11/17
to TerriaJS
Hi Kevin,

Thanks for the help, I can see most WMS services but I'm getting the CORS error when I try to add the service of this resources:

- http://mtcgeo2.mtc.gob.pe:8080/geoserver/MTC_gis/wms
- http://websig.senamhi.gob.pe:8080/WMS_CLASIFICACION_CLIMATICA/wms?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetCapabilities
- http://geoserver.igp.gob.pe:8080/geoserver/SCTS_Sismologia/wms

I've tried adding the domains in the allowProxyFor list in devserverconfig.json but I get the same error:

Failed to load http://mtcgeo2.mtc.gob.pe:8080/geoserver/MTC_gis/puerto_dic15/wms?service=WMS&version=1.3.0&request=GetCapabilities: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:3001' is therefore not allowed access.

The reason could be the 8080 port? or maybe because i'm testing in a localhost or I missing something in the configuration?

Kevin Ring

unread,
Oct 11, 2017, 6:34:36 PM10/11/17
to TerriaJS
Yeah you need to add "mtcgeo2.mtc.gob.pe:8080" to the proxy list.  Also, don't forget to restart the server to make the new proxy list take effect.

Kevin

--
You received this message because you are subscribed to the Google Groups "TerriaJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to terriajs+unsubscribe@googlegroups.com.
To post to this group, send email to terr...@googlegroups.com.
Visit this group at https://groups.google.com/group/terriajs.
For more options, visit https://groups.google.com/d/optout.

Darwin Denis Quispe Llancacuro

unread,
Oct 17, 2017, 5:23:43 PM10/17/17
to TerriaJS
Hi,

Yes, it worked, thanks!
Kevin

To unsubscribe from this group and stop receiving emails from it, send an email to terriajs+u...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages