1. yum install httpd

2. config /etc/httpd/conf/httpd.conf

<VirtualHost *:80>
  ServerName www.linuxidc.local
  DocumentRoot /wwwroot/www/
</VirtualHost>
<Directory “/wwwroot/www/”>
    Requireall granted
</Directory>

3.systemctl enable httpd.service

4.systemctl start httpd.service

05-29 01:19