Setting up multiple domains and subdomains on one droplet?

will add info via mobile

Show comments

Submit an answer

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!

Sign In or Sign Up to Answer

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.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Hello, it isnt that hard to get something like this and easily to find on google. I think you searched on the wrong keywords ;) Just add the domains you would like to use to your digital ocean domain manager. To get this working you need to setup your nameservers correctly. Login to the domain manager of your registrar, edit the nameservers to the nameservers of DO and it should work after some time.

Once you got the domains in the DO domainmanager, you need to create A records for the subdomains etc. to your static IP. So people will get redirected to your server.

After this you are almost done. Now you got the domain working, redirected to your server , you got to let your server handle the domain/subdomain to the proper directory. This depends on the kind of webserver you are using. With apache you need to use a different kind of virtual host than when you are using nginx for example. Just search for apache ,or whatever webserver your using, virtual host.

Hope this helps you, if I missed something im sorry im on my ipad currently.

Thanks, I am using apache and was trying different configurations with the virtual host, I can search more on it though