Tuesday, December 28, 2010

How to install Mongrel2 on Ubuntu with little pain

This post is about installing the latest and greatest of Mongrel2. Moreover - it is biased towards my needs (e.g. Mongrel2 repository automatically exported into git repository from fossil in the process of installation - because I am used to git more; as well as installs my gliese framework and dependencies.)

With that disclaimer, here is the magic link:


what you need to do is wget this file and then run it:

wget --no-check-certificate https://github.com/ayourtch/gliese/raw/master/examples/m2-dist/install

Certificate check is disabled because wget seems to dislike the wildcard cname in the cert. Alas.

When you download this file, run it - "sh ./install".

The first batch is a lot of packages that are installed via apt-get, and it will prompt for the sudo password.

After that bunch of packages/software are downloaded in source form - namely: zeromq, redis, fossil, mongrel2 and the associated lua libraries from github.

When the installation has finished, you can test it:

"cd dist/lua/gliese/examples/m2-site; sh run-all-in-screen"

and then connect with the browser to http://localhost:6767/lua1 - this will present you a small dynamic page with the counter stored in redis. This allows to see that all the components are installed and are functional.

If you want to hack on mongrel2 - then feel free to poke in mongrel2-git directory - that one contains the git repository autoconverted from fossil in the process of install. I liked fossil a lot - but just got used to git more, so that's the reason I do it in this script.


No comments: