Virtualhost subsomains don't work with Dokku

June 23, 2014 2.1k views

I am using an Ubuntu 14.04 machine with Dokku installed. I followed the instructions in these tutorials

And made sure to setup subdomains and everything else. The issue is I deployed a Rails app to a fresh Droplet and it was launched at the root of my hostname, rather than at the subdomain, as I thought it would.

In addition, when I go to this address:

It says the host name could not be resolved.

So I created a second app and deployed that too. Same thing at the subdomain of app 2.

Then I checked the docker processes, and I see this:


Both apps are mapping to the same port. Ok, I guess that's ok as long as the virtualhosts work. But they don't. So I don't know what else to do.

1 Answer

Remember to check the box labeled "Use virtualhost naming for apps" when you first browse to the IP address. The seu up view looks like:

If you don't, then you will have to access the apps over their port instead of by subdomain.

  • I'm experiencing a similar issue, I did the configuration for virtualhost naming but the issue still persists. I have even confirmed that the VHOST file exists in the /home/dokku directory path and is populated with the domain name.

  • How do you enable virtualhost naming after the server was setup and a dokku app is already created/running?

Have another answer? Share your knowledge.