What is in this tutorial?

Well, this time around I'm going to show you how to setup your media server so that you can access files and stream your music from/to any internet enabled computer. Out of all 3 tutorials so far, this one should be the easiest. So if you have been able to follow along this far this part should be easy as pie.

Disclaimer:

I'm sure there are all sorts of security risks open right now. I am fairly knowledgeless on Apache so if you can help me out by making this more secure please let me know here.

Before you bash me and email me junk like, "this is common knowledge" or "anyone with access to Google can do this," I want to let you know that this is for the people who don't know how or are just plain lazy.

Setup Process

This time around we are not going to install anything. If you followed my previous tutorials all the necessary applications we need are already installed. All that has to be done now is some simple configuration. Let's begin... Open Putty and SSH into your server once again.


1. Update Ubuntu

If you haven't updated in awhile this process might take some time, no more than 10 minutes. Updating is very important; do it regularly.
sudo apt-get update

sudo apt-get upgrade

2. Forward your ports!

I am assuming you have a router. By default ports are blocked. We need to open these ports so that we can connect to the server from outside the network.
Visit portforward.com, find your router, select Apache from the long list of applications, and follow the directions on that page to forward the needed ports. If you already know how to forward ports then forward both 80 and 443 to the IP of your server.

3. Create a homepage

Create a simple homepage. I made an image based one, you can find it right here (Username is "USERNAME" and Password is "PASSWORD"), and download it right here. For a link to Jinzora create a link which points to "jinzora2/", that's your Jinzora directory obviously. For html help visit W3Schools.
Please notice the included PHP files. password_protect.php is called from the index file which creates the login page which you see on my example page. The source files include instructions so follow those to get the login form set up.

4. Move index to the home directory of your server.

Copy the page you created to your Samba share and from Putty execute this command making changes as neccesary. The only thing you have to change is the original location of the index file on your server. If you've followed my tutorial word for word the following will work.
sudo mv /home/samba/index.html /var/www/
or
sudo mv /home/samba/index.php /var/www/

5. Test it

Type in your servers IP address into your browser to make sure the html file you created is displaying fine. If everything is running well ask your friend to visit your external IP address or use a proxy or cellphone, anything that is not on your network.
Your external IP is: 84.72.94.30.

6. Enjoy

Easy said, easy done.

Coming soon...

Hell if I know. I'm out of ideas, so leave me some.