Keep Server Online
If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.
or
A donation makes a contribution towards the costs, the time and effort that's going in this site and building.
Thank You! Steffen
Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
| |
|
Topic: Alias problem with virtualhost |
|
Author |
|
Qmpeltaty
Joined: 06 Feb 2008 Posts: 182 Location: Poland
|
Posted: Thu 09 May '13 11:46 Post subject: Alias problem with virtualhost |
|
|
Hi
I can't access to some alias page by http://mydomain.com/static/logo.jpg (getting 403 - Forbidden) but i can by https - https://mydomain.com/static/logo.jpg- what could be wrong ?
Config :
Code: | <VirtualHost 10.7.10.10:80>
ServerName mydomain.com
ServerAlias www.mydomain.com
DocumentRoot "c:/Apache24/htdocs"
Alias /static "d:/static"
<Directory "d:/static">
Options +Indexes +FollowSymLinks
AllowOverride all
Require all granted
</Directory>
</VirtualHost>
|
Code: | <VirtualHost 10.7.10.10:443>
DocumentRoot "C:/Apache24/htdocs"
ServerName domain.com
ServerAlias www.domain.com
SSLEngine on
SSLProtocol -ALL +SSLv3 +TLSv1
SSLCipherSuite ALL:!aNULL:!ADH:!eNULL:!LOW:!EXP:RC4+RSA:+HIGH:+MEDIUM
SSLCertificateFile "conf/ssl/domain.crt"
SSLCertificateKeyFile "conf/ssl/domain.key"
SSLCertificateChainFile "conf/ssl/domain.crt"
Alias /static "d:/static"
<Directory "d:/static">
Options +Indexes +FollowSymLinks
AllowOverride all
Require all granted
</Directory>
</VirtualHost> |
What could be wrong as the config is exactly the same for both VirtualHosts ? |
|
Back to top |
|
Steffen Moderator
Joined: 15 Oct 2005 Posts: 3118 Location: Hilversum, NL, EU
|
Posted: Thu 09 May '13 12:05 Post subject: |
|
|
Try to remove Alias /static "d:/static" from the vhosts and add to the main conf. |
|
Back to top |
|
James Blond Moderator

Joined: 19 Jan 2006 Posts: 7404 Location: EU, Germany, Next to Hamburg
|
Posted: Sat 11 May '13 12:14 Post subject: |
|
|
Steffen wrote: | Try to remove Alias /static "d:/static" from the vhosts and add to the main conf. |
That would make the alias global for any vhost. My guess is a permission problem from windows, not apache. |
|
Back to top |
|
Qmpeltaty
Joined: 06 Feb 2008 Posts: 182 Location: Poland
|
Posted: Mon 13 May '13 8:23 Post subject: |
|
|
James Blond wrote: | My guess is a permission problem from windows, not apache. |
I don't think so. It's the same apache instance, so the same processes. If the https vhost is accessing the directory properly then why http is not - both are involved with the same process = have same access rights. |
|
Back to top |
|
|
|
|
|
|