v 7.0 v 9.0 v 10.0 v 12.0 Third Party 1534
Download for v 7.0
Availability
Odoo Online
Odoo.sh
On Premise
Community Apps Dependencies
Technical Name server_environment
LicenseLGPL-3
Websitehttp://www.camptocamp.com
Versions 13.0 7.0 12.0 14.0 15.0 9.0 10.0 16.0
You bought this module and need support? Click here!

Environment file pattern for OpenERP

This module provides a classical configuration by environnement file pattern into OpenERP. Based on code written by WinGo and Camptocamp.

This module allows you to use the classical environment file pattern by reading a directive call running_env in the OpenERP configuration file:

[options]
running_env=dev / prod / etc.

We intended to add a server command line but there is no correct way to do it.

This method allows you to keep your settings into a module instead of using config files that might be mixed with openerprc or altered. It is an alternative way to the base config file for such configuration needs . All your configurations will be read only and accessible under the admin menu. If you are not in the 'dev' environment you will not be able to see the values contained in keys named 'passw'.

At the current time, the module does not allow to set low level attributes such as database server, etc. .

The first goal of the module is to ensure that OpenERP will never mess up the external system. Once installed, profile is mandatory. We do not want to launch an instance in the dev environment on a production server.

The configuration files are stored in the server_environment_files module, and user config parser module syntax. Look at the module to get some examples. The default configuration are stored in the default/ directory. You can add one directory for each environment you want to define, named after the environment. All config defined in non-default environments will override or complement the default config. If your attibutes contain passw, it will only be shown in the dev environment.

Example usage

from server_environment import serv_config
for key, value in serv_config.items('external_service.ftp'):
   print (key, value)

serv_config.get('external_service.ftp', 'tls')

Please log in to comment on this module

  • The author can leave a single reply to each comment.
  • This section is meant to ask simple questions or leave a rating. Every report of a problem experienced while using the module should be addressed to the author directly (refer to the following point).
  • If you want to start a discussion with the author, please use the developer contact information. They can usually be found in the description.
Please choose a rating from 1 to 5 for this module.