Obroll - obroll.com - Django Best Practice - How to build Django for production
General Information:
Latest News:
Install LXML in Debian 26 Nov 2012 | 06:49 pm
To install LXML python module in Debian, you need to install depedency packages : 1apt-get install python-dev libxml2 libxml2-dev libxslt1-dev libbz2-dev libssl-dev p7zip-full rar lha unrar unzip unac...
Solve slow DNS in HpCloud due to double reload on the website 25 Sep 2012 | 04:06 am
I found something weird with my Bind in HPCloud which it’s working well in my EC2. After trying several experiment, I found the correct way to set bind in HPCloud. This is for example: 123456789101112...
Solving Bind DNS un-resolved when nslookup domain without WWW 13 Sep 2012 | 07:36 pm
This is common mistake when we try to nslookup our domain that working with “WWW” but not without “WWW”. This is some bind9 configuration : 123456789101112131415; ; BIND data file for local loopback i...
How to sort instance by key or values inside list in Python 4 May 2012 | 04:43 pm
Sometimes we need to sorting a list which contain instances. And we need to sort by instances keys or values. This commonly happen in Django. So, basically, we just assign instance into dictionary an...
Solve EnvironmentError: mysql_config not found Mysql-Python pip on Ubuntu 12 Apr 2012 | 04:32 pm
If you installing MySQL-python from pip in Ubuntu and see this error : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46...
Setup Logger in Django 1.3 to show warning & error in console development 23 Mar 2012 | 04:49 am
New guys in Django commonly have a headache to see Logger configuration in settings.py. Sometimes people only want use Logger to print error / warning / debug in server development. Here are how to do...
Example how to rsync and restart services remote server using Fabric 21 Mar 2012 | 03:50 am
Fabric is great tools in Python which can ease our development. You can start installing it by : 1 sudo pip install fabric Let create some example cases here. 1. I have remote server which have po...
create simple example JSON REST API in Django 1.3 19 Mar 2012 | 01:53 am
Creating REST JSON API in Django in pretty easy. I know several django modules like django-tastypie, django piston, etc provide easy ways to build REST API in Django, but at this time, I will show sim...
Python Requests Module get Json content into dictionaries 18 Mar 2012 | 09:33 pm
Requests Module is great python module to use urllib2 in easy ways. For instance, let we get some JSON from my Gravatar : 1 https://es.gravatar.com/bashlook.json In case you need how to get JSON va...
Delete FileField using delete(save=False) in signals post_delete Django 7 Mar 2012 | 08:16 pm
We can’t overwrite delete() for deleting FileField and related files in Django. As we know that : In Django 1.3, when a model is deleted the FileField’s delete() method won’t be called. If you need c...