SCIENTIFIC-LINUX-USERS Archives

January 2013

SCIENTIFIC-LINUX-USERS@LISTSERV.FNAL.GOV

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Alex Kruchkoff <[log in to unmask]>
Reply To:
Alex Kruchkoff <[log in to unmask]>
Date:
Fri, 11 Jan 2013 16:55:34 +1100
Content-Type:
text/plain
Parts/Attachments:
text/plain (91 lines)
What about putting

<Directory /var/www/html/mysite>
   Order Deny,Allow
   Allow from all
   AddHandler cgi-script .cgi
   Options +Indexes +ExecCGI +FollowSymLinks
   DirectoryIndex index.cgi
   AllowOverride Limit Options FileInfo
</Directory>

before
</VirtualHost> line?


and remove it from  /etc/httpd/conf.d/mysite.conf

or  you can move the whole virtual host from global httpd.conf into 
conf.d directory if you have Include for that dir in global config.

Also on my web servers we usually use different IP for different web 
sites (if they require SSL encryption); these IP lives in /etc/hosts, 
like 1.2.3.4 virtualhost-mysite.com

and

<VirtualHost virtualhost-mysite.com:80>

Also don't forget to check for Listen virtualhost-mysite.com 80 directive.

Cheers
Alex
CS DBA wrote, On 11/01/13 10:14 AM:
> Hi all;
>
> I'm setting up a new web server, and I'm pretty good with Linux in 
> general but I am not an apache expert.
>
> Here's the overall problem:
>
> I have a website (mysite.com)
>
> I've installed Scientific linux & configured a base apache install.
>
> I setup a virtualhost entry in the http.conf file to include a 
> ServerName and a ServerAlias
>
> I added a conf.d/myhost.com.conf file with a Directory entry
>
> I've also setup a static IP address and a dns entry via noip.com so 
> mysite.com and www.mysite.com both resolve to our static IP
>
> At this point I can go to www.mysite.com and my web browser goes to 
> the site as expected,
>
> However if I point my browser to mysite.com I get redirected to the 
> default scientific linux apache test page.
>
> Thanks in advance for any help/advice...   Se the config details below:
>
>
> ===============================================
>
>
> Our /etc/httpd/conf/http.conf file includes this:
>
>
> <VirtualHost *:80>
>     DocumentRoot /var/www/html/mysite
>     ServerName mysite.com
>     ServerAlias www.mysite.com
> </VirtualHost>
>
>
>
> And our /etc/httpd/conf.d/mysite.conf file looks like this:
>
> <Directory /var/www/html/mysite>
>   Order Deny,Allow
>   Allow from all
>   AddHandler cgi-script .cgi
>   Options +Indexes +ExecCGI +FollowSymLinks
>   DirectoryIndex index.cgi
>   AllowOverride Limit Options FileInfo
> </Directory>
>
>
>
>
> Thoughts?

ATOM RSS1 RSS2