Hi Kirby,
To be technically true, you can’t really “point a domain to a subfolder”, put you can point a domain to an IP, as required by DNS to go on a website using a domain name instead of its IP.
So, in your situation, I much advise you to use Nginx as a reverse proxy, thanks to the use of server_name directives and document root location.
For example, if you want to host many websites on your VPS at IP 111.111.111.11, you can create as many folders you want in /var/www folder, and configure all your nginx virtualhosts to point the correct folder.
tree /var/www/
├── drupal_1
├── drupal_2
Once you have the following tree in your document root, you can use server_name directives to separate your drupal instances relied to a domain name with Nginx, with a configuration file of that kind :
server {
listen *:80;
server_name drupal_1;
root /var/www/drupal_1;
location / {
try_files $uri $uri/index.html $uri.html @upstream;
}
location @upstream {
your php-fpm configuration
}
}
server {
listen *:80;
server_name drupal_2;
root /var/www/drupal_2;
location / {
try_files $uri $uri/index.html $uri.html @upstream;
}
location @upstream {
your php-fpm configuration
}
}
Thanks to that kind of Nginx configuration, I guess that you will be able to do what you are looking for,
Hope this could help,
Best regards,
–
rustx
What OS and WebServer are you using ?
You can’t do it via DO control panel you have to point your domain name to the VPS IP address and than use software like Putty to SSH onto your VPS and setup configuration for your web server in your case I’m guessing apache2.