Re: IP address show Apache welcome page but domain name working!

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jason Long wrote:
When I visit my website by its IP address the welcome page of Apache showed, but with"https://domain-name.net";  everything is OK. How can I block direct access by IP or forward it to domain?

In the 000-default.conf put these lines:


RewriteEngine on
RewriteRule ^/ https://your.domain.name/ [R,L]

Retart httpd then it will work.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx




[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux