Introduction
According to the survey from http://www.netcraft.com/ , the Apache HTTP Server (Apache) is the world’s most widely-used Web server.
Apache is Developed by the Apache Software Foundation (http://www.apache.org/),
it is available for most operating systems. SUSE® Linux Enterprise Server includes Apache version 2.4.
In this article: learn how to install, configure and set up a Web server;
apache network diagram
before moving to configure SAMBA
let us to have a look to above network diagram
SLES will be configured sa apache HTTP server
since SLES in DMZ [servers farm] : we we have to consider network firewall [which is PFsense in our case ]
STEP 01 : install package [apache2 ] on SLES
first of all we have to check if package apache2 [which is responsible of running apache ] is installed or NOT
use command :
zypper info apache2
if apache2 is NOT installed > then simply install it using command
zypper install --no-confirm apache2
Step 02 configure apache2
open file /etc/sysconfig/apache2
and set the following parameters :
APACHE_SERVERADMIN="administrator@pioneers.lab"
APACHE_SERVERNAME="networks-pioneers"
APACHE_SERVERTOKENS="Prod"
Then save and exit
open file /etc/apache2/httpd.conf
and set the following parameters :
DirectoryIndex index.html index.htm
Then save and exit
Step 03 : start services apache2
now we have to check if service apache2 is running
use command :
systemctl status apache2
if NOT started then > start it
systemctl start apache2
also we have to Enable apache2 during system startup
systemctl enable apache2
Step 04 : Enable firewall rule for http & https
create firewall rule to enable http & https
firewall-cmd --permanent --add-service=http --permanent
firewall-cmd --permanent --add-service=https --permanent
then reload firewall
firewall-cmd --reload
Step 05 : open port 80 ,443 on firewall PF-sense
to it’s time to open port 80 ,443 in network firewall
it’s depend on your network firewall , in networks pioneers : we are using network firewall PFsense
Create a HTML test page
Open file /srv/www/htdocs/index.html
And insert code
<html>
<body>
<div style=”width: 100%; font-size: 40px; font-weight: bold; text-align: center;”>
Welcome To Network Pioneers
</div>
</body>
<body>
<div style=”width: 100%; font-size: 40px; font-weight: bold; text-align: center;”>
This is First Web Page
</div>
</body>
</html>
access web site from client PC with web browser
we can access web site using url
http://172.16.100.123
or
http://sles123
also we can add alias record [networks-pioneers ]for sles123
http:networks-pioneers