So, you want to host your website from your home or office may have. This tutorial will show you how to set up a basic web server using Linux. For this tutorial I have used Linux Mint 9 but the same work on any recent Linux distribution.
The first thing to do is OK to give the server a static IP address on the network. Once you assign a static IP address you must download and install the software you need. Open a terminal and install the following packages:
Apache2 php5 libapache2-May-MOD-PHP5 MySQL server
During the installation process you will be prompted for May root password. Make this something that is complex, but do not forget it!
Once installed open a web browser and type the server address in the address bar (eg 192.168.1.3) and you will see a message that works! This means that you have a web server works.
Now it’s time to add some content to your server. All data on the Apache web server stores in / var / www as the default, but you can not write to this folder. Open a terminal and type:
Enter the password when prompted. Click to go to / var and right on www. Then go to Properties. Add yourself and the owner or group and give yourself to “create and delete files, access to the folder.”
The next thing to do is download some FTP software. Personally I would recommend FileZilla. Open a terminal and type:
Sudo apt-get install filezilla
Once installed to connect to an existing Web site and transfer files in / var / www.
Congratulations! And now host your website on the new server but will not become clear until now on the internet. Most network sits behind a router that acts as a firewall, so make your web site and obviously you’ll need to route HTTP packets from your router to the server by opening port 80 and redirect to the IP address of the new service. Forward.com harbor is a good starting point for understanding the shipping port.
You also need to talk to your ISP about getting a static IP address for your router. Without this will not be able to access your website at any time to change your IP address.
And that is it! You now have a basic web server to host your web site.