Newbie Q: how to use a "standard" CGI from Zope?
Hi All, I have some CGIs written in C and Fortran, compiled to EXEs and currently running on Apache (without Zope), and tested on IIS (without Zope) as well. How can I integrate these into Zope ZServer setup with a minimum of rewriting? I have access to the source code, but would like to change it as little as possible (re-invention of wheels, and all that). I had a look at the Zope docs on External Methods and the Python docs on extending Python using C, but this didn't seem to click -- am I on the right track? Thanks very much, Arian ------------------------------------------------------------------ Arian de Wit, MSc(Hons), i-Net+, MCSE Information Systems Integration Manager NIWA (National Institute of Water & Atmospheric Research) Gate 10 Silverdale Road, Box 11-115, Hamilton, New Zealand Phone (+64) 7-856 1769 Fax (+64) 7-856 0151 Web http://www.niwa.cri.nz ------------------------------------------------------------------
Probably the easiest way to do this is to just write an External Method that sets up your environment in a Python dictionary and the executes your CGI in that environment using os.execv() and friends. There isn't much reason to run a CGI through Zope, though. Probably a better solution would be to run Zope behind Apache instead of ZServer and just have Apache handle the CGI stuff. Hope this helps, --jfarr ----- Original Message ----- From: "Arian de Wit" <a.dewit@niwa.cri.nz> To: <zope@zope.org> Sent: Monday, June 18, 2001 6:39 PM Subject: [Zope] Newbie Q: how to use a "standard" CGI from Zope?
Hi All,
I have some CGIs written in C and Fortran, compiled to EXEs and currently running on Apache (without Zope), and tested on IIS (without Zope) as well.
How can I integrate these into Zope ZServer setup with a minimum of rewriting? I have access to the source code, but would like to change it as little as possible (re-invention of wheels, and all that).
I had a look at the Zope docs on External Methods and the Python docs on extending Python using C, but this didn't seem to click -- am I on the right track?
Thanks very much,
Arian
------------------------------------------------------------------ Arian de Wit, MSc(Hons), i-Net+, MCSE Information Systems Integration Manager NIWA (National Institute of Water & Atmospheric Research) Gate 10 Silverdale Road, Box 11-115, Hamilton, New Zealand Phone (+64) 7-856 1769 Fax (+64) 7-856 0151 Web http://www.niwa.cri.nz ------------------------------------------------------------------
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
participants (2)
-
Arian de Wit -
Jonothan Farr