[Tilecache] Tilecache under mod_wsgi
Gissur Þórhallsson
gissur at loftmyndir.is
Thu Jan 28 05:24:55 EST 2010
Thank you both for your pointers. They were most helpful - at least I'm
getting errors from python now :)
I'm a bit confused thought - it's complaining that it can't find paste,
which is understandable, since paste is not installed.
Do I need paste if I'm running under mod_wsgi? I was under the impression
that it was only required for wsgi standalone...
Kind regards from Iceland,
Gissur
On Thu, Jan 28, 2010 at 10:05 AM, <manel.clos at ajgirona.cat> wrote:
> Hi Gissur,
>
> Here is the tilecache.wsgi script I'm using:
>
> # In Apache2's config:
> # WSGIScriptAlias /tilecache /data/tilecache/tilecache.wsgi
>
> import os, sys
> tilecachepath, wsgi_file = os.path.split(__file__)
> if not tilecachepath in sys.path:
> sys.path.append(tilecachepath)
>
> from TileCache.Service import Service, wsgiHandler
>
> cfgfiles = (os.path.join(tilecachepath, "tilecache.cfg"))
>
> theService = {}
> def wsgiApp (environ, start_response):
> global theService
>
> cfgs = cfgfiles
> if not theService:
> theService = Service.load(cfgs)
> return wsgiHandler(environ, start_response, theService)
>
> application = wsgiApp
>
> The script assumes to be in the tilecache dir, along the tilecache.cfg
> file.
>
> Hope this helps.
>
> ------------------------------
> *De:* tilecache-bounces at openlayers.org [mailto:
> tilecache-bounces at openlayers.org] *En nombre de *Gissur Þórhallsson
> *Enviado el:* jueves, 28 de enero de 2010 4:30
> *Para:* tilecache at openlayers.org
> *Asunto:* [Tilecache] Tilecache under mod_wsgi
>
> Hello,
>
> I'm setting up a tilecache instance and wanted to try using mod_wsgi.
> The thing is that I'm running python 2.6 and have other things that depend
> on that version of python otherwise I'd just use mod_python.
>
> I've got apache 2.2 running on a windows 2003 server already - and mod_wsgi
> up and running. I just have no idea how to plug tilecache into that.
>
> Has anybody had any experience running tilecache under mod_wsgi? Any
> pointers?
>
> Kind regards from Iceland,
> Gissur Þórhallsson
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/tilecache/attachments/20100128/b564946e/attachment.html
More information about the Tilecache
mailing list