Installing Apache Web Server on Centos 7

We update the operating system

[[email protected]]# yum update

Install Apache

[[email protected]]# yum install httpd

Add the server to startup and start it

[[email protected]]# systemctl enable httpd.service
[[email protected]]# systemctl start httpd.service

Open ports 80 (http) and 443 (https)

[[email protected]]# firewall-cmd --permanent --zone=public --add-service=http
[[email protected]]# firewall-cmd --permanent --zone=public --add-service=https
[[email protected]]# firewall-cmd --reload
Sidebar