Skip to Content
Menu
This question has been flagged
3 Replies
6644 Views

I create an dir named "my_modules" which  I want to save my own modules;

and now I want to add this dir into "addons_path" for all databases;

I do as below:

 odoo.py --save --config myodoo.cfg --stop-after-init (then edit myodoo.cfg and edit it:  addons_path = ~/odoo-dev/my_modules,~/odoo-dev/odoo/openerp/addons,~/odoo-dev/odoo/addons)

then : ~/odoo-dev/odoo/odoo.py -c ~/odoo-dev/myodoo.cfg --stop-after-init -u base  

after that I run :~/odoo-dev/odoo/odoo.py , I find I still can;t add my own dir.

How shall I do that?

Avatar
Discard
Best Answer

Add the path to your openerp-server.conf file and execute Odoo by specifying the conf file as parameter. I would run Odoo as a service anyway (systemd or upstart, if you are using Ubuntu).

Avatar
Discard
Author

thank you.

I check this and I just find file "openerp-server" in '../odoo' rather than 'openerp-server.conf';

I want to start "odoo" just by ".../odoo/odoo,py" and my own dir "my_modules" will be auto loaded;not each time specifying some certain file as paramete, shall I?

Please locate the openerp-server.conf file in your installation (in an Ubuntu install you'll find it in /etc/odoo/openerp-server.conf). There you can add your custom addons path. You may then start odoo with the parameter -c path/to/your/openerp-server.conf

Author

Ok

thank you!

Best Answer

dear vx2008

 you can use this command to start the server what ever you want to put 
"my_modules"  any way:
./odoo.py --addons=your pure addons path,"my_modules" path.
I hope i helped you.

Avatar
Discard
Author

hey Adam, thank you for your advice and I have a try;

yes, odoo will load the modules which were saved in "my_modules" when I run the code:"./odoo.py --addons=your pure addons path,"my_modules" path."; but next time I type "./odoo.py", the modules in "my_modules" will never be loaded; In the fact I want to do some setting, and then each time type "./odoo.py" to lead these modules.

Related Posts Replies Views Activity
2
Oct 16
7142
1
Dec 23
2635
0
Sep 23
2732
1
Oct 24
3422
1
Feb 23
23300