Current time: 11-25-2024, 09:40 PM Hello There, Guest! (LoginRegister)


Post Reply 
Preview Website without DNS pointed
Author Message
kilburn Offline
Development Team
*****
Dev Team

Posts: 2,182
Joined: Feb 2007
Reputation: 34
Post: #6
RE: Preview Website without DNS pointed
(08-02-2009 02:02 AM)sidha Wrote:  The simple method:
1. at one of your already working domain's htdocs dir (/var/www/virtual/alreadyworkingdomain.com/htdocs) make a dir with the name of your new domain:
Code:
mkdir newdomain

2. type:
Code:
mount --bind /var/www/virtual/newnotworkingdomain.com/htdocs/ /var/www/virtual/myalreadyworkingdomain.com/htdocs/newdomain/

3. point your browser to http://myalreadyworkingdomain.com/newdomain/

(To unmount later: umount /var/www/virtual/newnotworkingdomain.com/htdocs/)
(note: at step 2. there is one line with a space between the two paths)

This is a valid method for apache+mod_php but not for fastcgi/fcgid (ispcp default). The reason is that each domain belongs to a different user and, therefore, http://myalreadyworkingdomain.com/newdomain/ will throw you a 403 Forbidden error when trying to run php/cgi scripts...

Quote:Thank you kilburn ! This is a smart solution which can also be apply for alias preview (and maybe for subdomain preview using *.*.users IN A IP.OF.YOUR.SERVER)
You're welcome! Smile My own tests show that the record "*.users IN A" already resolves "*.*.users IN A" queries, so you should only need to edit the ServerAlias directives in the respective template files (something like subdmn_entry.tpl, als_entry.tpl) and it should automagically work for subdomains/aliases too Smile
08-02-2009 10:34 AM
Visit this user's website Find all posts by this user Quote this message in a reply
Post Reply 


Messages In This Thread
Preview Website without DNS pointed - ctct - 05-23-2009, 01:16 AM
RE: Preview Website without DNS pointed - kilburn - 08-02-2009 10:34 AM

Forum Jump:


User(s) browsing this thread: 4 Guest(s)