Re: cgi script as domain root index (howto)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Tim Johnson <tim@xxxxxxxxxxxxxxxx> [101031 15:05]:
> This questions concerns apache(2) on ubuntu 10.04 and apache on
> centOS (OS version 7?)
> Using the following apache directive:
>    ScriptAlias /reg/ /home/http/py/
>     <Directory "/home/http/py">
>         AllowOverride all
>         Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
>         Order allow,deny
>         Allow from all
>     </Directory>
> 
> And the following .htaccess directives:
> #
> RewriteEngine on
> RewriteCond %{REQUEST_FILENAME} !-f
> RewriteRule ^(.*)$ ./index.py/$1 [L,QSA]
> #
> I can point my browser to http://localhost/reg/
> (with trailing slash) and get a response from
> 'index.py'
> Two questions ::
> 
> 1)How may I configure apache so that users will not need the
> trailing slash?
> 
> 2)How may I configure apache so that pointing my browser to
> http://localhost 
> will give me the response from a CGI script at /home/http ?
  Well, I have done some 'poking around'. I have altered the
  configuration of /etc/apache2/mods-enabled/dir.conf
  with the following directive:
  ##
  DirectoryIndex index.html index.php index.py index.cgi index.pl
  index.xhtml index.htm
  ##
  I can verify that index.html and index.php will work, based on the
  priority of the file entries. However, if I rename both index.php
  and index.html - I get the following error message:
  """
  You don't have permission to access /index.py on this server
  """
-- 
Tim 
tim at johnsons-web.com or akwebsoft.com
http://www.akwebsoft.com

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux