Report this

What is the reason for this report?

I think I only did about half the proess to get my additional domain to point to a sub directory.

Posted on April 6, 2016

I’m using serverpilot if that helps and my directory structure is

/apps/thekitribe/public/(root directory)

I was hoping my additional domain, say abc.com was hosted at

/apps/thekitribe/public/abc/

I’ve messed around with the networking tab here on DO and edited some conf files on server pilot all of which I’ve just un-done because the guides i’m reading (not DO specific) are leading me in all various directions.

Do I need to setup a “virtual host” with apache? Isn’t DO a VPS? Big moment of confusion for me. ;-)

What I have now: (both thexeno.com and kitribe.com both point to same numerical domain–top level.)

I’d like thexeno.com to remain top level and then kitribe.com to be in perhaps the /apps/thekitribe/public/kitribe folder.

Sorry if I’m over-complicating this but I’m probably more confused then I should be at the moment lol.

Cam



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hi, you can use this same guide whether your additional domain is a registered domain or a subdomain:

https://serverpilot.io/community/articles/how-to-serve-a-subdomain-from-a-subdirectory.html

You definitely shouldn’t customize any config files for this. In other words, you don’t need to use root at all. SSH in as the app’s system user and create the symlink as described in the ServerPilot documentation. That is, create a second app under the same system user, delete this new app’s “public” directory and in its place make a symlink to the directory in the other app you want it to use as the new app’s web root directory, and add your domain to the new app in ServerPilot.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.