[GeoNode-users] Error 405 not permitted

David Alda Fernandez de Lezea dalda at hazi.eus
Wed Feb 17 03:12:13 PST 2016


Hi,

Thanks for your response Alessio.

I think it has nothing to do with what I mentioned previously. I’ve checked the contents of each tile of the preview image and I’m getting some coords really away from our extent although the SRS is OK. My mistake.

-76.43702827394,0,0,76.43702827394

I've added to the javascript code a coordinate transformation. Now it zooms to where it should, but it doesn't load the layer.

Would this probably be related to the fact that GeoNode supposes that everything that comes with an SRS different from EPSG:900913 it turns to EPSG:4326?

Because in the Django admin web, I've seen in the layers properties that there's a field SRS (filled with ESG:4326) and other fields with the corresponding bbox.

Is there a way to change this programatically?

In which python is this set?

Thanks and sorry for the mistake.

Regards,

Agur bero bat,



David Alda Fernández de Lezea
Área de Sistemas de Información Geográfica, Planificación Territorial y Forestal Informazio Geografikoen Sistemak, Lurralde eta Baso Antolaketaren Arloa.
dalda at hazi.eus | www.hazi.eus
T 945 003 240 – M 627 923 170 – F 945 003 290 
Hazi | Granja Modelo de Arkaute s/n | 01192 Arkaute – Araba
 
*********************  LEGE OHARRA   *******************   AVISOLEGAL   *******************   DISCLAIMER   *****************************
Mezu hau pertsonala eta isilpekoa da eta baimenik gabeko erabilera debekatua dago legalki. Jasotzailea ez bazara ezabatu mezua, bidali eta kontserbatu gabe.
Este mensaje es personal y confidencial y su uso no autorizado está prohibido legalmente. Si usted no es el destinatario, proceda a borrarlo, sin reenviarlo ni conservarlo.
This message is personal and confidential, unauthorised use is legally prohibited. If you are not the intended recipient, delete it without resending or backing it.

De: alessio.fabiani at gmail.com [mailto:alessio.fabiani at gmail.com] En nombre de Alessio Fabiani
Enviado el: miércoles, 17 de febrero de 2016 10:05
Para: David Alda Fernandez de Lezea
CC: geonode-users at lists.osgeo.org
Asunto: Re: [GeoNode-users] Error 405 not permitted

Mmm,
I'm not fully sure this method is valid

 url:"/gs/" + workspace + layer.params.LAYERS

I guess /gs/ is a GeoNode Proxy to GeoServer, used by GeoServer itself to get the authorization rules from GeoNode.

I'm not fully sure the workspace is supported, but I may be wrong.




Best Regards,
Alessio Fabiani.

==
GeoServer Professional Services from the experts!
Visit http://goo.gl/it488V for more information.
==

Ing. Alessio Fabiani
@alfa7691
Founder/Technical Lead

GeoSolutions S.A.S.
Via di Montramito 3/A
55054  Massarosa (LU)
Italy
phone: +39 0584 962313
fax:     +39 0584 1660272
mob:   +39 333 8128928

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------

AVVERTENZE AI SENSI DEL D.Lgs. 196/2003
Le informazioni contenute in questo messaggio di posta elettronica e/o nel/i file/s allegato/i sono da considerarsi strettamente riservate. Il loro utilizzo è consentito esclusivamente al destinatario del messaggio, per le finalità indicate nel messaggio stesso. Qualora riceviate questo messaggio senza esserne il destinatario, Vi preghiamo cortesemente di darcene notizia via e-mail e di procedere alla distruzione del messaggio stesso, cancellandolo dal Vostro sistema. Conservare il messaggio stesso, divulgarlo anche in parte, distribuirlo ad altri soggetti, copiarlo, od utilizzarlo per finalità diverse, costituisce comportamento contrario ai principi dettati dal D.Lgs. 196/2003.
 
The information in this message and/or attachments, is intended solely for the attention and use of the named addressee(s) and may be confidential or proprietary in nature or covered by the provisions of privacy act (Legislative Decree June, 30 2003, no.196 - Italy's New Data Protection Code).Any use not in accord with its purpose, any disclosure, reproduction, copying, distribution, or either dissemination, either whole or partial, is strictly forbidden except previous formal approval of the named addressee(s). If you are not the intended recipient, please contact immediately the sender by telephone, fax or e-mail and delete the information in this message that has been received in error. The sender does not give any warranty or accept liability as the content, accuracy or completeness of sent messages and accepts no responsibility  for changes made after they were sent or for other risks which arise as a result of e-mail transmission, viruses, etc.
---------------------------------------------------------------------

On Tue, Feb 16, 2016 at 2:11 PM, David Alda Fernandez de Lezea <dalda at hazi.eus> wrote:
Yes, I guess so, I haven't changed anything related to GeoNode and Geoserver configuration. Everything is in the same machine.
 
The changes I made in the code are (in red):
 
/usr/local/lib/python2.7/dist-packages/geonode/settings.py
 
LOCAL_GEOSERVER = {
        "source": {
            "ptype": "gxp_wmscsource",
            "url": OGC_SERVER['default']['PUBLIC_LOCATION'] + "geonode/wms",
            "restUrl": "/gs/rest"
        }
    }
 
 
/var/www/geonode/static/geonode/js/extjs/GeoNode-mixin.js
 
layer.url.indexOf(app.localGeoServerBaseUrl.replace(app.urlPortRegEx, "$1/")) === 0)) {
                
                    var workspace="geonode:";                    
                    if (layer.params.LAYERS.indexOf(":")!=-1){
                        workspace = "";
                            }
                Ext.Ajax.request({
                    /* TODO: use a template variable here if possible */
                    url:"/gs/" + workspace + layer.params.LAYERS + "/edit-check",
                    method:"POST",
                    success:function (response) {
                        var result = Ext.decode(response.responseText);
                        if (result.authorized === false) {
                            toggleButtons(false);
                        } else {
                            layer.displayOutsideMaxExtent = true;
                            toggleButtons(true);
                        }
                    },
                    failure:function () {
                        toggleButtons(false);
                    }
                });
            } else {
                toggleButtons(false);
            }
 
 
Thanks.
 
Regards.
 
Agur bero bat,
 
 
David Alda Fernández de Lezea
Área de Sistemas de Información Geográfica, Planificación Territorial y Forestal Informazio Geografikoen Sistemak, Lurralde eta Baso Antolaketaren Arloa.
dalda at hazi.eus | www.hazi.eus
T 945 003 240 – M 627 923 170 – F 945 003 290 
Hazi | Granja Modelo de Arkaute s/n | 01192 Arkaute – Araba 
*********************  LEGE OHARRA   *******************   AVISOLEGAL   *******************   DISCLAIMER   *****************************
Mezu hau pertsonala eta isilpekoa da eta baimenik gabeko erabilera debekatua dago legalki. Jasotzailea ez bazara ezabatu mezua, bidali eta kontserbatu gabe.
Este mensaje es personal y confidencial y su uso no autorizado está prohibido legalmente. Si usted no es el destinatario, proceda a borrarlo, sin reenviarlo ni conservarlo.
This message is personal and confidential, unauthorised use is legally prohibited. If you are not the intended recipient, delete it without resending or backing it.
 
De: alessio.fabiani at gmail.com [mailto:alessio.fabiani at gmail.com] En nombre de Alessio Fabiani
Enviado el: martes, 16 de febrero de 2016 13:24
Para: David Alda Fernandez de Lezea
CC: geonode-users at lists.osgeo.org
Asunto: Re: [GeoNode-users] Error 405 not permitted
 
Are GeoServer and GeoNode under the same domain? (same hostname and same port)?
 
 
Best Regards,
Alessio Fabiani.
 
==
GeoServer Professional Services from the experts!
Visit http://goo.gl/it488V for more information.
==
 
Ing. Alessio Fabiani
@alfa7691
Founder/Technical Lead
 
GeoSolutions S.A.S.
Via di Montramito 3/A
55054  Massarosa (LU)
Italy
phone: +39 0584 962313
fax:     +39 0584 1660272
mob:   +39 333 8128928
 
http://www.geo-solutions.it
http://twitter.com/geosolutions_it
 
-------------------------------------------------------
 
AVVERTENZE AI SENSI DEL D.Lgs. 196/2003
Le informazioni contenute in questo messaggio di posta elettronica e/o nel/i file/s allegato/i sono da considerarsi strettamente riservate. Il loro utilizzo è consentito esclusivamente al destinatario del messaggio, per le finalità indicate nel messaggio stesso. Qualora riceviate questo messaggio senza esserne il destinatario, Vi preghiamo cortesemente di darcene notizia via e-mail e di procedere alla distruzione del messaggio stesso, cancellandolo dal Vostro sistema. Conservare il messaggio stesso, divulgarlo anche in parte, distribuirlo ad altri soggetti, copiarlo, od utilizzarlo per finalità diverse, costituisce comportamento contrario ai principi dettati dal D.Lgs. 196/2003.
 
The information in this message and/or attachments, is intended solely for the attention and use of the named addressee(s) and may be confidential or proprietary in nature or covered by the provisions of privacy act (Legislative Decree June, 30 2003, no.196 - Italy's New Data Protection Code).Any use not in accord with its purpose, any disclosure, reproduction, copying, distribution, or either dissemination, either whole or partial, is strictly forbidden except previous formal approval of the named addressee(s). If you are not the intended recipient, please contact immediately the sender by telephone, fax or e-mail and delete the information in this message that has been received in error. The sender does not give any warranty or accept liability as the content, accuracy or completeness of sent messages and accepts no responsibility  for changes made after they were sent or for other risks which arise as a result of e-mail transmission, viruses, etc.
---------------------------------------------------------------------
 
On Tue, Feb 16, 2016 at 1:02 PM, David Alda Fernandez de Lezea <dalda at hazi.eus> wrote:
Hi list,
 
I'm continuing with our GeoNode customization. One of our requirements was to show in the GeoExplorer Local GeoServer combo only the layers from "geonode" workspace. So far I've been able to modify everything and get it working, but I've found an issue while accessing layer details. I get an HTTP 405 error METHOD NOT ALLOWED while accessing http://192.168.1.190/gs/rest/styles
 
HTTP/1.1 405 METHOD NOT ALLOWED
Date: Tue, 16 Feb 2016 11:39:17 GMT
Server: Apache/2.4.7 (Ubuntu)
Vary: Accept-Language,Cookie
X-Frame-Options: SAMEORIGIN
Content-Language: es
Content-Length: 0
Keep-Alive: timeout=5, max=100
Connection: Keep-Alive
Content-Type: text/plain
 
And the layer is not displayed in the preview. Apache doesn't show any error.
 
Can anyone point me to the file(s) that I have to change?
 
Thanks in advance.
 
Regards,
 
Agur bero bat,
 
 
David Alda Fernández de Lezea
Área de Sistemas de Información Geográfica, Planificación Territorial y Forestal Informazio Geografikoen Sistemak, Lurralde eta Baso Antolaketaren Arloa.
dalda at hazi.eus | www.hazi.eus
T 945 003 240 - M 627 923 170 - F 945 003 290
Hazi | Granja Modelo de Arkaute s/n | 01192 Arkaute - Araba
 
*********************  LEGE OHARRA   *******************   AVISOLEGAL   *******************   DISCLAIMER   *****************************
Mezu hau pertsonala eta isilpekoa da eta baimenik gabeko erabilera debekatua dago legalki. Jasotzailea ez bazara ezabatu mezua, bidali eta kontserbatu gabe.
Este mensaje es personal y confidencial y su uso no autorizado está prohibido legalmente. Si usted no es el destinatario, proceda a borrarlo, sin reenviarlo ni conservarlo.
This message is personal and confidential, unauthorised use is legally prohibited. If you are not the intended recipient, delete it without resending or backing it.
 
_______________________________________________
geonode-users mailing list
geonode-users at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/geonode-users
 
 

_______________________________________________
geonode-users mailing list
geonode-users at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/geonode-users



More information about the geonode-users mailing list