Month: December 2014

Django django-admin.py startproject ImportError

Django django-admin.py startproject ImportError

Suddenly i got this error in Windows when trying to start a new Django project : 1django-admin.py startproject ImportError: No module named django.core The solution : 1python C:\Python27\Scripts\django-admin.py startproject example

Set Ofbiz using database PostgreSQL

Set Ofbiz using database PostgreSQL

Here is a quickstep to set OfBiz running using PostgreqSQL 1. Install PostgreSQL Driver Download http://jdbc.postgresql.org/download/postgresql-9.3-1102.jdbc4.jar and put it on “ofbiz\framework\entity\lib\jdbc” 2. Setup new account and database In Pgadmin, right click on “Login Role” and create a new account “ofbiz” with password “ofbiz”. Also create database called “ofbiz” and the owner is “ofbiz”. Make sure …

+ Read More

Install and setup Ofbiz in Windows Server

Install and setup Ofbiz in Windows Server

1. Download and install Java JDK (I prefer 1.7) and set JAVA_HOME in Global Environment Variables into your jdk : Example : C:\Program Files\Java\jdk1.7.0_45 2. Go to http://www.apache.org/dyn/closer.cgi/ofbiz/apache-ofbiz-13.07.01.zip and select mirror to download 3. Extract the package into your local folder 4. Open your command-prompt, and do : 12ant load-demo ant start 5. Now open …

+ Read More

Install OpenERP in Windows Server / 8

Install OpenERP in Windows Server / 8

Here is a quickstep to install openerp in windows : 1. Download OpenERP http://nightly.odoo.com/8.0/nightly/exe/odoo_8.0.latest.exe 2. Setup Postgresql Account I assume we already have postgresql in our Windows. Go to PgAdmin -> Server -> Login Role. Right click on Login Role and select New Login Role. Create a new account called “odoo” with create database permission. …

+ Read More

How to rollback or remove last commit in remove Git

How to rollback or remove last commit in remove Git

This is common thing can happen when we push bad commit and want to rollback into previous commit. Please try this in your own branch before apply into production / master. Try with “git log” : 1234567891011commit 10a8e361b35dd8131cb1ba3e606aad35d0d0f267 Author: Somebody Date:   Fri Dec 26 13:02:33 2014 +0700      Bad commit here commit f89150c864cd4725a25995efd233f5beab7fc25d …

+ Read More

Setup rsync in Windows

Setup rsync in Windows

Please go to http://www.rsync.net/resources/howto/windows_rsync.html and download the software. Then you can add “C:\Program Files (x86)\cwRsync\bin” into your global variable path

Set Postgresql open for remote access in EC2

Set Postgresql open for remote access in EC2

To make PostgreSQL can be accessible from remote, first in EC2 security, please open your port “5432” (if your installation is using default port). Next, we need to edit pg_hba.conf : /etc/postgresql/9.3/main/pg_hba.conf and add : 1host    all             all             0.0.0.0/0       …

+ Read More

Celery as daemon service in Ubuntu for production

Celery as daemon service in Ubuntu for production

Here is a quickstep to set Celery as daemon in Ubuntu 14.04 for production: Create file “/etc/init.d/celeryd” : 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395#!/bin/sh -e # ============================================ #  celeryd – Starts the Celery worker daemon. # ============================================ # # :Usage: /etc/init.d/celeryd {start|stop|force-reload|restart|try-restart|status} # :Configuration file: /etc/default/celeryd # # See http://docs.celeryproject.org/en/latest/tutorials/daemonizing.html#generic-init-scripts ### BEGIN INIT INFO # Provides:         …

+ Read More

Install OpenERP in Ubuntu

Install OpenERP in Ubuntu

To install open-erp in Ubuntu : 123wget -c https://raw.githubusercontent.com/aschenkels-ictstudio/openerp-install-scripts/master/odoo-v8/ubuntu-14-04/odoo_install.sh chmod a+x odoo_install.sh ./odoo_install.sh Edit “/etc/odoo-server.conf” : 12345678[options] ; This is the password that allows database operations: ; admin_passwd = admin db_host = localhost db_port = 5432 db_user = username db_password = password addons_path = /usr/lib/python2.7/dist-packages/openerp/addons Make sure your add username and password PostgreSQL account that …

+ Read More

Install Django in Windows 8 / 7

Install Django in Windows 8 / 7

Here is quick step to setup Django in windows box : 1. Install Python Please download https://www.python.org/ftp/python/2.7.7/python-2.7.7.msi. 2. Install Setuptools http://www.lfd.uci.edu/~gohlke/pythonlibs/4jci5y59/setuptools-5.8.win32-py2.7.exe 3. Install PIP http://www.lfd.uci.edu/~gohlke/pythonlibs/4jci5y59/pip-1.5.6.win32-py2.7.exe 4.Don’t forget to set global environment variables (depend on your Python path installation) In PATH, please add : 1C:\Python27\;C:\Python27\Scripts;C:\Python27\Lib\site-packages\django\bin; 5. Install Django 1pip install django 6. Create new django project …

+ Read More

Solve RabbitMQ ERROR: epmd error for host “ubuntu”: address (cannot connect to host/port)

Solve RabbitMQ ERROR: epmd error for host “ubuntu”: address (cannot connect to host/port)

When installing RabbitMQ in server, I got this errors: 123456789101112131415161718192021Preparing to unpack …/rabbitmq-server_3.2.4-1_all.deb …                 Unpacking rabbitmq-server (3.2.4-1) …                                     yProcessing triggers for man-db (2.6.7.1-1) …           …

+ Read More

Configure Django Celery, RabbitMQ in Windows and periodic task

Configure Django Celery, RabbitMQ in Windows and periodic task

Here is guide to setup Django, Celery, RabbitMQ in Windows and running periodic task. 1. Install RabbitMQ Go to http://www.rabbitmq.com/download.html, install and check if the services already running 2. Setup celery in your Django Project Install django-celery modules 1pip install django-celery 3. Example configuration for periodic task In this example, i create tasks.py in app …

+ Read More