httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ron Wingfield" <dtc...@ionet.net>
Subject CGI and ScriptAlias Alternatives
Date Tue, 04 Jun 2002 01:01:03 GMT
RE:  the directory structure below:  I want to contain general purpose CGI scripts in sub-directories
under the /www/cgi-bin/ directory.  These objects only need one common occurrence on the system.
 I want these objects segregated by type with regard to Perl Scripts, C objects, unix shell
scripts, Java , ad nauseam.

I'm having difficulty executing the counter.pl in the common directory.  If I add a ScriptAlias,
e.g.,

  ScriptAlias /cgi-bin/   "/www/cgi-bin/perl/"

to the httpd.conf container for the VirtualHost, apples.com.


After execution of the index.htm file in the host's DocumentRoot directory, /www/vhosts/apples.com
(as directed in the httpd.conf file), the error-log message contains:  "invalid CGI ref "www/cgi-bin/perl/counter.pl".
 For the present, I am trying to understand the system of overrides, aliases, etc., without
the added complexity of suEXEC.   I do plan to go there, but only after getting a handle on
a simpler configuration.  Regardless, I am using .htaccess files in target directories, and
with some success.  For example, I have a perl script, wiggle.pl, in the VirtualHost structure
for apples.com which is successfully executed by the wiggle.htm, . . .as long as I do not
include the previously described ScriptAlias.  From what I've read, the concept of ScriptAlias
seems rather restrictive with regard to managing executables in a hierarchal directory structure.
 

Can I still use default ScriptAliases to point to multiple hierarchal directory structures
for executables, as in the following example, and still use local directory overrides? 


/www/
----------cgi-bin/
          ----------perl/
                    ----------counter.pl
          ----------C/
          ----------Java/
          ----------unix_shell/
----------data/
          ----------page_counters
----------htdocs/
= = = = = = = = = = = = = = = = = = = = = = = = = = = = =
----------vhosts/
          ----------apples.com/
                    ----------.htaccess
                    ----------htdocs/
                              ----------Yet_another_dir/
                                        ----------.htaccess
                                        ----------wiggle.htm
                    ----------Index.htm
                    ----------cgi-bin/
                              ----------perl/
                                        ----------wiggle.pl
                              ----------Java_Script/
          ----------oranges.com
          ----------whatever.com



Mime
View raw message