Create a personal webserver on the ReadyNAS

March 21, 2008 by yoh-dah  
Filed under How-To's

Tired of paying to have your website hosted somewhere or getting a free website that doesn’t quite give you the creative freedom to do what you really want? Well, that little ReadyNAS you use for sharing, backup, streaming, and photo sharing, can become your web server as well. Let’s take a look at why you might want to do this.

  1. ReadyNAS can be on 24/7 while using very little power.
  2. Updates to your website is quick — there’s no need complicated process to update your changes. Just drag & drop if you want.
  3. If you’re CGI-savvy, you can create a dynamic site easily with Perl or PHP.
  4. You can create a dynamic DNS hostname for free and redirect that to your webserver, or you can sign up for your own domain and point that to your ReadyNAS.
  5. Your website is protected with RAID.

OK, you’re convinced and you want to get started. Let’s go over the steps that you’ll need to follow.

  1. Create a share on the ReadyNAS where you want to put your website files.
  2. Redirect default HTTP access to your ReadyNAS to this website share.
  3. Create a test index.html and verify access.
  4. Forward external HTTP access to your ReadyNAS.

So, let’s get started.

Step 1 – Create a website share

We’ll call it website. You’ll need to give it Read-only access to the share over HTTP and enable write access over CIFS if you will be updating the share via Windows or AFP if you will be using a Mac.

httpshare.jpg

Step 2 – Redirect default HTTP access

From the Services/Standard File Protocols tab, select the website share from the drop-down list in the HTTP box to redirect default web access. This will prevent the web share list from showing when you access http://<readynas_ip>. Instead it will automatically redirect to http://<readynas_ip>/website.

httpredirect.jpg

Step 3 – Create a test index.html

Now create index.html with the following content and drag & drop to the website share.

<html>
  <body>Welcome to my personal ReadyNAS website!</body>
</html>

In your browser, enter the following (replace <readynas_ip> with your ReadyNAS IP):

http://<readynas_ip>

You should see the following:

test.jpg

Step 4 – Forward external HTTP access to your ReadyNAS

At this point, we’re ready to make the HTTP access to your ReadyNAS public. In this step, we’ll modify your router to forward all incoming HTTP access (port 80) to your ReadyNAS. Make note of your router login and password and follow the steps outlined here to forward port 80 to your ReadyNAS IP. The link provides specific instruction for your router.

After you’ve done this, find out what your external public IP is. You can do this easily by visiting:

http://whatsmyip.org

Using this public IP, test if you get the same web page from Step 3. Enter the following in your browser (replace <public_ip> with your external IP):

http://<public_ip>

Congratulations — you’ve just setup your own webserver!

And now, the finishing touches

Now that you’ve setup the basic server, what’s next.

  1. First, you’ll need to setup a hostname that you and the rest of the world can remember easily. DynDNS offers free hostnames using a pre-defined list of domains (i.e. dyndns.org, homedns.org, homeip.net) so that you can have something like mygreatwebsite.homedns.org.
  2. If you want, you can get your own domain name from places like yahoo.com and godaddy.com. This way you can have something like www.mygreatwebsite.com instead.
  3. You’ll want to replace your index.html with something a little more creative. You can use a web page editor such as DreamWeaver to quickly come up with creative static pages.
  4. If you want to utilize CGI and you’re Linux-savvy, you can use the built-in Perl interpreter or install PHP. You can find instructions on how to install PHP here.
  5. You can host a blog on your new ReadyNAS website by following the how-to here.
1 Star2 Stars3 Stars4 Stars5 Stars (39 votes, average: 4.31 out of 5)
Loading ... Loading ...

Comments are closed.