VirtualHost always returns default host with Apache on Ubuntu 14.04

前端 未结 12 604
夕颜
夕颜 2021-01-30 07:16

I try to setup a virtual host besides the default localhost. Whenever I try to call my virtual host http://test I get the default Apache2 Index file t

12条回答
  •  粉色の甜心
    2021-01-30 07:53

    I ran through all of these solutions and none of them worked. Then, I decided to go back and check the apache2.conf file. I discovered that the line to include the "sites-enabled" conf files was commented out by default. By uncommenting the line and restarting apache, it fixed my problem (it was close to the end of the file):

    # Include the virtual host configurations:
    IncludeOptional sites-enabled/*.conf 
    

提交回复
热议问题