Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

Registry Entry For CGI - Windows XP

 [1/3] from: tim-johnsons::web::com at: 16-Feb-2005 12:32


I'm in a real bind here. I'm trying to do CGI programming on Windows XP, testing with the windows version of apache, to be deployed on a linux server, also using apache. The Windows apache server on my machine is properly configured to ignore the she-bang line (top line) of a script. This should enable me to place #!/usr/bin/rebol at the top line of a script and have it accepted by the linux server. This works for python, because the python setup program has written the appropriate regestry entries, but sadly (and in my opinion wrongly) rebol has no setup process that does this. And I'm getting "couldn't spawn child process" errors from apache. On the other hand, if I disable the ScriptInterpreterSource directive, then I have to resolve the differences between #!rebol on windows and #!/usr/bin/rebol on linux, which is what my domain hoster wants, and *that* introduces greater possibilities of error if one uploads a script without changing the shebang line. Please note: This is Windows XP *not* windows 98, apache *not* IIS. I'm familiar with the IIS/Windows 98 windows registry entries to enable this. HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W3SVC \Parameters does not have a ScriptMap key, and adding one doesn't help. Has anyone got this working successfully? thanks tim

 [2/3] from: SunandaDH:aol at: 17-Feb-2005 1:27


Tim:
> Has anyone got this working successfully?
This may not help directly. But this is what we do with REBOL.org. All CGI scripts have a shebang. The uploader (we wrote our own -- it does lots of useful things) will change the shebang (if there is one -- not all uploaded files are CGI scripts) to the correct shebang for the target destination. That enables each of us to have a fully working copy of the library, each with a different set-up (we range from Wni98+Xitami to Linux+Apache). The uploader simply changes the shebang to match the target. So no need to disable shebang detection under Windows -- which is a plus point, as it means scripts don't unexpected fail when uploaded if they have a mistyped or missing shebang. Sunanda.

 [3/3] from: tim-johnsons:web at: 17-Feb-2005 8:09


SunandaDH-aol.com wrote:
>Tim: >>Has anyone got this working successfully?
<<quoted lines omitted: 4>>
>lots of useful things) will change the shebang (if there is one -- not all >uploaded files are CGI scripts) to the correct shebang for the target destination.
Hi Sunanda: That is a great approach. I fact I've been toying with the idea of database-driven uploads where the database controls where the upload goes, makes a record of it, changes she-bang, etc. It turns out that my solution was to put rebol in c:\usr\bin. Even with ScriptInterpreterSource turned on, it appears that apache will still try to resolve the shebang line, and now it sees #!/usr/bin/rebol and resolves it to c:\usr\bin\rebol.exe And my domain hoster says that he would be happy to be set up symlinks at /usr/bin/rebol/rebol /usr/bin/python/python, usr/bin/perl/perl, etc. That would allows us to set up seperate folders for perl, rebol and python at c:\usr\bin\rebol\rebol.exe etc and set shebangs as #!/usr/bin/rebol/rebol et. al. This brings up another thought ..... some time ago (if memory serves me correctly) there was a url to a more advanced ftp system written in rebol. Does anyone know of it? Thanks for the ideas. tim

Notes
  • Quoted lines have been omitted from some messages.
    View the message alone to see the lines that have been omitted