Apache Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsSystem AdministrationApache Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old August 10th, 2007, 03:22 AM
honey bee honey bee is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2006
Location: Isl,Pakistan
Posts: 99 honey bee User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 5 h 9 m 37 sec
Reputation Power: 4
Question Apache Virtual Directory

Hello,

I have read the following way to create virtual directory in apache:

Quote:
# Alias for all php test sites
Alias /testsites_php "/Applications/GoLive_Preconfigured_Servers/TestSites/php"
<Directory "/Applications/GoLive_Preconfigured_Servers/TestSites/php">
Options Indexes FollowSymLinks MultiViews ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>


If i'll just use:

Alias /testsites_php "/Applications/GoLive_Preconfigured_Servers/TestSites/php"

, for virtual directory, will it be ok?

Reply With Quote
  #2  
Old August 10th, 2007, 08:15 AM
jharnois's Avatar
jharnois jharnois is offline
mod_dev_shed
Dev Shed God 20th Plane (14500 - 14999 posts)
 
Join Date: Sep 2002
Location: Atlanta, GA
Posts: 14,732 jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level)jharnois User rank is General (90000 - 100000 Reputation Level) 
Time spent in forums: 1 Month 1 Week 3 Days 14 h 52 m 36 sec
Reputation Power: 977
The alias itself will work, yes, but that doesn't mean your visitors will be able to see the contents of the aliased directory. Whether or not it "works" will depend on other settings in httpd.conf.

Apache has a default <Directory /> section that forbids access, effectively forbidding access to the entire file system. It then has a <Directory> for your DocumentRoot that overrides this restriction. In your example, the associated <Directory> is there to ensure permissions are granted to the directory to which the Alias points. Without it, you're relying on a parent directory of the aliased directory to have been given "open" permissions.

It's probable that there's a <Directory /Applications/GoLive.../TestSites"> that handles opening up that directory (and all subdirectories) already, in which case you would not need a <Directory> for the /php subdirectory.
__________________
# Jeremy

Explain your problem instead of asking how to do what you decided was the solution.

Reply With Quote
Reply

Viewing: Dev Shed ForumsSystem AdministrationApache Development > Apache Virtual Directory


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump



 Free IT White Papers!
 
How to Present Effectively Online
This white paper offers practical and actionable advice on the key steps that any presenter should consider as they plan and execute a Webinar or online meeting.

 
Open Source Security Myths
Open Source Software (OSS) is computer software whose source code is available to the general public with relaxed or non-existent intellectual property restrictions (or arrangement such as the public domain), and is usually developed with the input of many contributors.

 
Power and Cooling Capacity Management for Data Centers
This paper describes the principles for achieving power and cooling capacity management.

 
Scalable, Fault-Tolerant NAS for Oracle - The Next Generation
For several years NAS has been evolving as a storage alternative for Oracle databases, and for good reason: NAS is quite often the simplest, most cost-effective storage approach for Oracle. Learn about the benefits that HP's approach to scalable NAS brings to Oracle environments in this comprehensive white paper.

 
Understanding Web Application Security Challenges
This white paper discusses many common threats and preventive measures for Web application security, and explains what you can do to help protect your organization.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2009 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway
Stay green...Green IT