Pages

Wednesday 6 March 2013

How to install rapidsms in Ubuntu (12.10)



RapidSMS is a free and open-source framework for dynamic data collection, logistics coordination and communication, leveraging basic short message service (SMS) mobile phone technology (according to rapidsms.org). RapidSMS is a python program built on top of django. This is a quick "how to" to have rapidsms quickly set up on an Ubuntu machine. It is seven step process.

Step 1: install python-django, python-pip.

$sudo apt-get install python-django
$sudo apt-get install python-pip

Step 2: Install rapidsms from the cheeseshop.

$sudo pip install rapidsms

If you have rapidsms installed already, then you can upgrade it:
$sudo pip install -U rapidsms

Step 3: Next install the http router

$sudo pip install rapidsms-httprouter

Step 4: Now that all is set, create a new project like so:

$cd
$rapidsms-admin.py startproject my_project

Please replace the my_project with the appropriate/desired name of your project.
Django will notice that you do not have a super user/admin account for the new project that you are creating so it will suggest that you create one. Enter the user name you desire and password. I suggest you oblige and enter these!

Step 5: Now create the db. If the name of the project in Step 4 was my_project, then;

$cd my_project

Else $cd name_of_your_newly_created_project

Now create/sync the db.
$python manage.py syncdb

Step 6: Try accessing the webUI of your newly created installation. Personally, I prefer running programs that capture my prompt using screen
So part (a) of this process is optional

(a) $screen

(b) $python manage.py runserver 0.0.0.0:8000
       or
       $python manage.py runserver

     $ Ctrl - A + D (to exit screen----you may need to read the screen manual pages)

       The first Option allows you to acess the rapidsms WebUI both locally and remotely and the second    allows you to access the rapidsms WebIU locally only. Personally, I prefer the first option because I develop most apps in VMs (Virtual Machines)

(c)  $python manage.py runrouter


You can access the admin interface that django assisted to create for you by typing this: http://your_ip_address:8000/admin. Enter the user name and password you created in Step 4.

There you are!!! You now have a barebones rapidsms installation.!!!



2 comments:

Unknown said...

good straight forward steps to install rapidsms.

if you ever get this error like me :
Module "django.core.context_processors" does not define a "auth" callable request processor

just change the line in settings.py like said in this link :
http://stackoverflow.com/questions/7470179/module-django-core-context-processors-does-not-define-a-auth-callable-reques

Webmaster Freelance Paris said...

hello want to install rapidsms but I have this message?
I newbee in django

testserver
Note that only Django core commands are listed as settings are not properly configured (error: Requested setting INSTALLED_APPS, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings.).


impossible to install rapidsms