How to enable loopback connections over HTTP

6 posts / 0 new
Last post
#1 Wed, 07/22/2015 - 01:30
fuggi

How to enable loopback connections over HTTP

Hello, I've to enable loopback connections over HTTP for a specific website (virtual server), because I would like to use the CMS KOKEN (koken.me). May I add the following section to my Apache configuration:

<VirtualHost 127.0.0.1>
DocumentRoot /home/[username]/public_html
ServerName www.mydomain.com
ServerAlias mydomain.com
ServerAdmin webmaster@mydomain.com                                                                          
ErrorLog /var/log/virtualmin/mydomain/error_log
CustomLog /var/log/virtualmin/mydomain/access_log combined
</VirtualHost>

Would this confuse Virtualmin? Or is there an option in Virtualmin to enable loopback connections over HTTP for virtual servers?

Thank you very much in advance!

Best regards, fuggi

Wed, 07/22/2015 - 02:04
tpnsolutions
tpnsolutions's picture

Hi,

You may modify the Apache config however you'd like. Virtualmin won't mess with most modifications so you should be fine.

Best Regards,
Peter Knowles
TPN Solutions

Email: pknowles@tpnsolutions.com
Phone: 604-782-9342
Skype: tpnsupport
Website: http://www.tpnsolutions.com

Ask me about my new support plans which include a FREE copy of Virtualmin Pro!!!

Best Regards,
Peter Knowles | TPN Solutions
Email: pknowles@tpnsolutions.com | Skype: tpnassist
Wed, 07/22/2015 - 03:06 (Reply to #2)
fuggi

Hi Peter,
I thought so. However, what about my second question? Is there an option in Virtualmin to enable such functionality directly?

Best regards,
fuggi

Wed, 07/22/2015 - 03:46
fuggi

For some reason, my solution mentioned above does not work. After adding that part to /etc/apache2/sites-available/[mydomain].conf, loopback connections over HTTP are still not possible. Any ideas?

Thanks a lot in advance!

PS: Of course, the /etc/hosts file does contain the lines 127.0.0.1 localhost and [PublicIP] [ServerName]. However, [ServerName] is different from [mydomain].

Wed, 07/22/2015 - 03:54 (Reply to #4)
fuggi

Solved: My .htaccess directory protection blocked the connection, of course. Stupid me.

Thu, 07/23/2015 - 12:29
tpnsolutions
tpnsolutions's picture

Hi,

It looks like in your original sample code, you didn't specify "port".

<VirtualHost 127.0.0.1>

Should be:

<VirtualHost 127.0.0.1:80>

*** you can change "80" to different non-standard port as desired. ***

Best Regards,
Peter Knowles
TPN Solutions

Email: pknowles@tpnsolutions.com
Phone: 604-782-9342
Skype: tpnsupport
Website: http://www.tpnsolutions.com

Ask me about my new support plans which include a FREE copy of Virtualmin Pro!!!

Best Regards,
Peter Knowles | TPN Solutions
Email: pknowles@tpnsolutions.com | Skype: tpnassist
Topic locked