Hi Matthew, I dont have a specific answer to this question, Dwins may have some better insight, but I did want to let you know what OpenGeo is currently working on this same kind of problem as part of our work for the World Bank on the OpenDRI project. The idea there is to break up a single GeoNode site into multiple 'portals' that each have their own set of data and maps and allowing each portal to be themed as necessary. The plan is to do it with subdomains and the sites framework as you are doing it, and also to use the workspace concept in GeoServer to segment the layers and to provide separate WMS/WFS/WCS endpoints for each individual portal. Additionally, we are now using pycsw in place of GeoNetwork and are adding the concept of workspaces there too.
I wonder if we can have a wider discussion about this kind of use case as we begin to implement this. Jeff On Fri, Mar 30, 2012 at 8:13 AM, Matthew Hanson <[email protected]> wrote: > Hello, > > I've hit a roadblock in setting up multiple GeoNode sites. I'm > using the Sites framework with different sites, but using a single > database: > > geo.domain.com: master site with all data > siteA.domain.com: subset of data, apps > siteB.domain.com: subset of data, apps > > I'm using apache with mod_wsgi to run a process for each site. I have > geoserver and geonetwork proxies, so that each appear to be on each > domain, even though it's just one geoserver serving all sites. > > The problem is that GeoServer has the GEONODE_BASE_URL setting, which > is fixed in my web.xml. It actually works fine to authenticate, but > doesn't work with the sessions if you aren't on the main site, so > logging into GeoNode doesn't log you into GeoServer, you must go to > GeoServer separately and log in. > > So, if I set my GEONODE_BASE_URL to geo.domain.com, then logging into > geo.domain.com works fine, and I'm logged in to both GeoNode and > GeoServer. However, if I log into siteA.domain.com, it authenticates > to geo.domain.com, and although it works to log in to GeoNode, I am > not logged into GeoServer*. > > So I need some way to have GeoServer get the current SITEURL and > authenticate vs that, instead of based on the GEONODE_BASE_URL > parameter in web.xml. I was looking at where it gets it in > src/geoserver-geonode-ext/src/main/java/org/geonode/security/DefaultSecurityClient.java > : setApplicationContext > > Is there a way to get that property dynamically from the session ? > > > * at least right now, eventually I need to restrict log on to any > specific sub-domain to only users with permissions. > > > thanks, > > matt
