Install httpd to configure Web Server. HTTP uses 80/TCP.
[1] Install httpd.
[root@centos7apacheserver ~]# yum -y install httpd
[root@centos7apacheserver ~]# rm -f /etc/httpd/conf.d/welcome.conf
[2] Configure httpd. Replace server name to your own environment.
[root@centos7apacheserver ~]# vi /etc/httpd/conf/httpd.conf
ServerAdmin [email protected]
ServerName centos7apache.example.com:80
AllowOverride All
DirectoryIndex index.html index.cgi index.php
ServerTokens Prod
KeepAlive On
[root@centos7apacheserver ~]# systemctl start httpd
[root@centos7apacheserver ~]# systemctl enable httpd
[3] If Firewalld is running, allow HTTP service. HTTP uses 80/TCP.
[root@centos7apacheserver ~]# firewall-cmd --add-service=http --permanent
success
[root@centos7apacheserver ~]# firewall-cmd --reload
success
[4] Create a HTML test page and access to it from client PC with web browser. It's OK if following page is shown.
[root@centos7apacheserver ~]#
[root@centos7apacheserver ~]# echo "STEEMIT WEB SERVER" >> /var/www/html/index.html
[root@centos7apacheserver ~]#