Report this

What is the reason for this report?

How can I view a virtual host (apache ubuntu) without a domain name in place?

Posted on February 23, 2016

I have a droplet with Ubuntu, Apache, MySql (basically a WordPress setup). I then have 10 or so virtual hosts setup within that droplet for various websites and apps. I set up the virtual host as described HERE

Everything works great and I love the setup – but sometimes, I don’t have access to the domain name until the site is complete (for example, a client has a squareSpace site and doesn’t want it to come down until we’re ready to switch).

I need access to a WordPress back-end so the client and I can fill it with data to feed an Ember app at the root.

var/www/example-site/target-folder

Normally the IP address would just work, but with virtual hosts, I’m not sure how to get the to folder described above.

How can I reach this folder BEFORE I have a domain setup? Can I forward it in the .conf or the hosts file??? HELP! : )

104.236.45.XXXX/example-site/target-folder or a subdomain would be great too. example-site.104.236.45.XXXX/target-folder



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.

To add a dummy DNS name that is resolved locally, you can use the hosts file.

See this for more info.

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.