dear friends
so i have created a subdomain secure.domain.com and i pointed it to the main folder of domain.com,
i created custom vhost.conf for apache and that works great,
but nginx is pointing still to wrong folder, logical as i can see that the last_nginx.conf file is pointing to wrong place
so i found the thread
http://forum.parallels.com/showthread.php?260814-Nginx-configuration-for-vhosts
and i followed the indications there but its not working for me,
- i have edited a file nginxDomainVirtualHost.php
on /usr/local/psa/admin/conf/templates/custom/domain
after copying from the default folder
and i added this as you indicated
<?php if (file_exists($VAR->domain->physicalHosting->vhostDir . '/conf/nginx.conf')): ?>
include <?php echo $VAR->domain->physicalHosting->vhostDir;?>/conf/nginx.conf;
<?php endif ?>
just i wasnt sure where to add it, i added it at the very end before the last }
is that correct, or if not where should i add it within that file?
and then i added an nginx.conf inside
/var/www/vhosts/system/secure.domain.com/conf
and inside i just put
root "/var/www/vhosts/domain.com/httpdocs"
is that correct, or do i have to put more directives inside this custom nginx.conf?
and then i did of course the /usr/local/psa/admin/bin/httpdmng --reconfigure-all
but nothing happened
when i go to secure.domain.com i keep getting 404 nginx errors,
however the apache is pointing to right place because the .htaccess of main folder is getting processed, so apache all good,
but all php and non php pages are failing with 404 nginx errors still
i now tried something different, in plesk 11.5
i went to web server settings of the subdomain
and in extra nginx directives i added
location ~ /$ {
root /var/www/vhosts/domain.com/httpdocs;
}
that changed that now when going to
secure.domain.com instead of getting a 404 not found,
i get a 403 forbidden
other than that if i try
secure.domain.com/index.php i still get 404 error and same for other files
thank you for any help
best