I'm new to odoo. Recently, I need to automate our build process for odoo. And this is some approach that I intend to try
1. Use cli odoo.py as background process but the problem is that everytime I run odoo.py, it create a new process ?
2. I could create a daemon thread as describe in this tutorial https://www.linode.com/docs/websites/cms/install-odoo-9-erp-on-ubuntu-14-04. So that the CI server can stop/start odoo server easily.
I still struggling with #2 but cannot run the server successfully yet. Does anyone have experience automate the odoo build before and share the experience with me ?
Thanks a lot in advance.
After lots of time on #2 approach, I still cannot make odoo running in daemon thread. So I switch back to #1 and this is the final script that work for me. If you are in the same situation, hope that help.
sudo kill -9 /var/run/odoo-server.pid
/opt/odoo/odoo-server/odoo.py -d <db_name> -r <db_user> -w <db_password> --addons-path <addons path> -u <modules to update upon startup> > /var/log/odoo/odoo-server.log 2>&1 &
echo $! > /var/run/odoo-server.pid
Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!
About This Community
|Asked: 9/5/16, 6:18 AM|
|Seen: 192 times|
|Last updated: 9/6/16, 3:41 AM|