Rasberry pi web server project part 2 - Installing the web server

This is a continuation of my project to build a simple web application with my virtually untouched raspberry Pi whch my wife lovingly purchased for me last christmas.

Today I have installed the webserver application on the Raspberry pi.  There were two distinct phases to this.

Firstly deciding which web server to go for, and secondly to install it.

The first part was all about selecting what I wanted in a web server.  Given that I wanted really the feel of Googles App Engine the final choice was to go for Tornado.  Its written in python and I want a web server that can take me beyond the level of static pages.  I'm kind of thinking to start off with a simple microblog system - like Facebook for the Grimleys - Grimbook even?

The second part was really quite simple once the initial decision had been made.  Installing On the rasberry pi comes down to using the apt - package manager

sudo apt-get python-tornado

I also installed pip just to be on the safe side, but since apt is managing my packages I'm a little adverse to using more than one package manager.  I have no idea if one can uninstall or update packages installed from one manager using the other.  You could of course write a shell script to update all at the same time.  Keeping a single package manager seems like a simpler option.

sudo apt-get python-pip

In order to test the installation I used the basic script from the Tornado documentation saved into a file
called "server.py"
server base program

This was saved in my home folder in the pi then run using the command:

python server.py

Resulting web page 
This web page was then accessible using Safari on another computer.  The link did not work, but the feeling of success is still present.

Update:  fixed the link problem.  forgot to put "http://" in front of googles web address.

Comments

Popular Posts