官术网_书友最值得收藏!

Odoo server configuration files

Most of the options can be saved in a configuration file. By default, Odoo will use the .odoorc file. In Linux systems, its default location is in the home directory ($HOME), and in the Windows distribution, it is in the same directory as the executable used to launch Odoo.

In older Odoo/OpenERP versions, the name for the default configuration file was .openerp-serverrc. For backward compatibility, Odoo 10 will still use this if it's present and no .odoorc file is found.

On a clean install, the .odoorc configuration file is not automatically created. We should use the --save option to create the default configuration file, if it doesn't exist yet, and store the current instance configuration into it:

$ ~/odoo-dev/odoo/odoo-bin --save --stop-after-init

Here, we also used the --stop-after-init option to stop the server after it finishes its actions. This option is often used when running tests or asking to run a module upgrade to check whether it is installed correctly.

Now we can inspect what was saved in this default configuration file:

$ more ~/.odoorc  # show the configuration file

This will show all the configuration options available with their default values. Editing them will be effective the next time you start an Odoo instance. Type q to quit and go back to the prompt.

We can also choose to use a specific configuration file, using the --conf=<filepath> option. Configuration files don't need to have all the options you've just seen. Only the ones that actually change a default value need to be there.

主站蜘蛛池模板: 文水县| 灵台县| 江达县| 永新县| 怀安县| 南漳县| 东辽县| 余庆县| 正蓝旗| 邹平县| 左贡县| 宁河县| 文成县| 贵德县| 湛江市| 奉节县| 江口县| 博客| 万安县| 长泰县| 溧阳市| 驻马店市| 宁远县| 罗定市| 昌黎县| 额敏县| 唐海县| 鄂尔多斯市| 滨海县| 武宣县| 汨罗市| 蒲城县| 铜鼓县| 峨边| 禄丰县| 宁都县| 巴彦淖尔市| 革吉县| 盐城市| 曲水县| 广灵县|