Pergunta

We're running a pylons app with multiple ini files (production, staging, development, etc). When a new setting is added that can be the same in all environments, it would be great to be able to set it once in some sort of master configuration that gets included with all .ini files. Or included via some other way to load centralized config as well as deploy-specific config.

It doesn't look like there's an "import" syntax for pylons ini files. What's the best way to achieve this type of config compositing for pylons, if any?

Foi útil?

Solução

You can use the ConfigParser module.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top