An add-on for Plone
Project description
collective.regenv
This product allows to override the values stored in the portal registry and property manager object (i.e. a PAS plugin) with values defined on a local file defined in an environment variable called PLONE_REGISTRY_YAML.
When it comes to PropertyManager, this product actually only works if you use the accessor getProperty to read properties.
Features
Using this product you can:
have different values for development and production environments (think about the MailHost settings, connection parameters to external services, etc.)
have different values for different instances in the same buildout, allowing for example to toggle features on and off for A/B testing.
Documentation
Registry overrides should be in a YAML file:
% cat sample.yaml defaults: &defaults plone.cachepurging.interfaces.ICachePurgingSettings.cachingProxies: - http://localhost:8000 - http://localhost:8001 plone.app.theming.interfaces.IThemeSettings.hostnameBlacklist: - 127.0.0.1 - localhost /Plone/portal_registry: <<: *defaults /Plone2/portal_registry: <<: *defaults plone.cachepurging.interfaces.ICachePurgingSettings.cachingProxies: - http://localhost:9000
Run zope instance with environment pointing to the YAML file, for example:
PLONE_REGISTRY_YAML=$(pwd)/sample.yaml bin/instance fg
Or using the docker image, for example:
docker run -p 8080:8080 \ -e ADDONS=collective.regenv \ -e PLONE_REGISTRY_YAML=/app/registry.yaml \ -v$(pwd)/sample.yaml:/app/registry.yaml \ plone/plone-backend:latest
Installation
Install collective.regenv by adding it to your buildout:
[buildout] ... eggs = collective.regenv
and then running bin/buildout
Contribute
Issue Tracker: https://github.com/collective/collective.regenv/issues
Source Code: https://github.com/collective/collective.regenv
Documentation: https://pypi-hypernode.com/project/collective.regenv/
License
The project is licensed under the GPLv2.
Contributors
mamico, mauro.amico@gmail.com
Changelog
1.0.0a2 (2022-12-27)
Fix monkeys init [mamico]
1.0.0a1 (2022-12-27)
Initial release. [mamico]
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Hashes for collective.regenv-1.0.0a2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 668f4051158d47c4c05c022d200ba646ed79dd55147fbe3c831553b986effd1c |
|
MD5 | 4e1335cdbd49ba421b9bd9367bbf25d0 |
|
BLAKE2b-256 | 7ed5298394be1318819f985cf1dba786f241123e2002ac7658356f0f2536a7ce |