Keywords: LAMP/MAMP/WAMP - Linux - Technical issue - Other
bnsupport ID: f2591734-ec9c-0ff9-8ef6-8d4f92a74794
I’ve found a few other topics here on this subject, but none seem to offer a fix for my problem. Hopefully someone has more insight than I do…
I am trying to move my LAMP site to be served from varnish.
Up to now, I’ve been using port 80 for apache as usual. I also defined the default virtual host in
/opt/bitnami/apache/conf/bitnami/bitnami.conf" so that apache serves my app as the document root.
Following the bitnami instructions, I have switched things so that varnish listens on port 80, which apache is now on port 81. I followed the bitnami varnish instructions correctly, I’m almost sure.
At this point, I can see my site perfectly if I browse on port 81.
However, and here’s the problem, if I browse on port 80, via varnish, the document root is now the bitnami welcome index.html page. My site is only available by prepending the path to the app in the url.
It seems that varnish isn’t recognizing the virtual host that I defined in
/opt/bitnami/apache/conf/bitnami/bitnami.conf". (For the record, I updated the port in this file to 81, as well, as per the instructions.
Ideally, I’d like to force varnish to recognize the default virtual host I set up in apache. However, another workaround is possible: I’m only serving a single site off this machine, so I don’t believe I need the default virtual host. However, I couldn’t find another way to set the apache document root.
Thanks in advance for any help!