I wanted to host on my WhiteLight custom website / multiple websites without installing any additional web server (I'm re-using mini_httpd). I didn't want to switch off WD Configuration website either.
So here is what I did:
1. If you have registered domain (eg. www.mywebsite.com) map it to your IP address on your DNS server. Since I have dynamic IP I use ddclient (no-ip should work similar). Example:
Record Type = A; IP address = xxx.xxx.xxx.xxx Host = www.mywebsite.com
2. Set up sub-domains on your DNS (eg. nas.mywebsite.com, shop.mywebsite.com) using CNAME. They will point to your registered domain:
nas CNAME www.mywebsite.com
shop CNAME www.mywebsite.com
3. Create WWW directory somewhere on your WD where you want to store your files (eg. /shares/Public/WWW/)
4. In that WWW directory create sub-directories for your virtual hosts. Additionally create symbolic link to your original WD Configuration site (/proto/SxM_webui). The folder structure should look more less like this:
- ls -la
/shares/Public/WWW/nas.mywebsite.com -> /proto/SxM_webui
4. Place your website files in www.mywebsite.com, shop.mywebsite.com
5. Change startup script for mini_httpd (# nano /etc/init.d/S55mini_httpd):
replace: WEBROOT="/proto/SxM_webui" with WEBROOT="/shares/Public/WWW"
add parameter "-v" when mini_httpd is called
6. Restart mini_httpd:
- /etc/init.d/S55mini_httpd restart
7. Now when you type www.mywebsite.com in your browser it will take you to your default page in folder /shares/Public/WWW/www.mywebsite.com.
When you type nas.mywebsite.com it will take you to original WD Configuration site.
Hope it helps!