Pages

Navitron

2019-02-14

RISC OS web server

If you have read this blog before (and I am pretty sure at least one person has) you will know that I am a big fan of RISC OS on Raspberry Pi.

RISC OS is an operating system that has the 'look' of  Linux and the 'feel' of the BBC microcomputer. I have delved into various aspects of RISC OS Pi before.

Whilst looking for web server solutions for RISC OS, I recently discovered WebJames. WebJames is a server with an integrated PHP interpreter. It is available in the PackMan package manager and it is really easy to use. In this post I will show you how to set it up (really easy) and get going as a hoe server.

Once you have finished installing from PacMan, all you need to do is provide a folder called 'Site' and you are good to go.
Packman installs WebJames into :0.$.Apps.Web, however, you can easily move it to any location you like. As most of my files are stored on a removable USB stick, I've put WebJames there. This has got to be the simplest web server ever. No complex configuration; no mucking about with Linux; simply launch the server and point it at some HTML files. As long as WebJames is running on the pi it will dutifully listen on port 80 for any requests.

PackMan (not Pac-man)
There is also an example code package which is worth exploring.

I've only just scratched the surface of what we can do with WebJames, but I am certainly glad it exists.

The first thing you might want to do is create a test site. Here I have provided a new HTML file called index and placed it in the 'site' folder. The test page has a single link that opens a folder called 'files' (useful for grabbing files from the pi onto another machine).

The index test page is shown in StrongEd for RISCOS (although I actually wrote this in qedit for DOS under DOSBox for that extra geekiness).


My first test page running on my Samsung Galaxy Note. Not very exciting, just a link to a folder.

Directory listing of files on the server.

To view your web server test page on your home network, simply point your browser at http://your IP address, for example, mine is http://192.168.1.218

To view your page on your Raspberry Pi instead, try http://127.0.0.1

Well, that's all for today. We have only dipped our feet into the RISC OS server waters. I hope somebody found this a useful guide. I am certainly looking forward to doing more with this software. In fact, the Apache web server I have running on my second Pi is the only reason I actually have a second pi running at all. WebJames really makes RISC OS more and more attractive as an operating system. Oh, and did I mention that you can use BBC BASIC as a server-side scripting language?

If you enjoyed this post, then there is a slim chance you will enjoy this post about my experience of RISC OS on Raspberry Pi, or that time I installed DOSBox on Raspberry Pi, or even something completely different.

No comments:

Post a Comment