

Next, reload the firewall to put these new rules into effect:Īfter the firewall reloads, you are ready to start the service and check the web server.

Ensure that a basic firewall is configured by following Step 4 of the Initial Server Setup with CentOS 8 (recommended) in the above guide.Īpache is available within CentOS’s default software repositories, which means you can install it with the dnf package manager.Īs the non-root sudo user configured in the prerequisites, install the Apache package:Īfter confirming the installation, dnf will install Apache and all required dependencies.īy completing Step 4 of the Initial Server Setup with CentOS 8 guide mentioned in the prerequisites section, you will have already installed firewalld on your server to serve requests over HTTP.A non-root user with sudo privileges configured on your server, set up by following the initial server setup guide for CentOS 8.You will need the following to complete this guide:

In this guide, you will install an Apache web server with virtual hosts on your CentOS 8 server. It provides many powerful features including dynamically loadable modules, robust media support, and extensive integration with other popular software. The Apache HTTP server is the most widely-used web server in the world.
