multiple websites host one server

How to install Multiple Websites host on ubuntu server AWS and connect our domain name server I am starting with install apache server I am using AWS ec2-Machine

Installing Apache webserver on ubuntu server

changing directory cd command

Multiple Websites host
Creating two apache root directories for our website server
Multiple Websites host
Changing Permission our Web directories

Creating an index.html for testing purpose

I am copying the index.html file our second website root directory

Editing our second website default index.html file

Multiple Websites host
Multiple Websites host

creating a virtual-host our websites I am copy 000-default.conf file ctfplayer.com.conf and jameshacker.me.conf

Configure Virtual Host in Apache to host multiple domains

now configure our virtual host in apache configuration file Go to the apache conf location. ( in default installation – you will find it here /etc/apache2/sites-available

I am copying the default 000-default.conf to our domain name ctfplayer.com.conf and again copy the default 000-default.conf file to our second domain name ctfplayer.com.conf

Editing our first virtual host file ctfplayer.com.conf and add server name and our root directory

Editing our second virtual-host file jameshacker.me.conf

Multiple Websites host

enable our virtual-host configuration file

Multiple Websites host

now disable our default apache server configuration file 000-default.conf remember after disabling apache2 default configuration file default host is not working

after creating and enable our virutal-host we need to restart our apache2 server

Multiple Websites host
Configure our domain DNS record connection our server IP address

Go to your domain name provider and log in your account my case I am using Godaddy go to the Domains section and you see your domain now changing our DNS record for connecting our hosting server

Multiple Websites host

After click DNS we see our DNS Records now adding our hosting IP address remember to delete your old A Type records and click the add button choose to Type-A Records and Host section @ and Point to address (your hosting IP address and TTL Value is default and save button

Same configuration our second domain DNS record
Multiple Websites host

Add A record (associates a name with an IP address) server address and click save button to save our records file

Multiple Websites host
checking our Website is connect properly to our hosting server

ctfplayer.com Checking our first Website in the web browser and we see our first web site default web page index.html

Multiple Websites host

jameshacker.me Checking our Second Website in the web browser and again we see our default index.html file

Multiple Websites host

Joomla setup apache server read here