Browse Source

Add post_processor Manager configuration option/support

pull/1061/head
Ross McFarland 2 years ago
parent
commit
557d0eb1cb
No known key found for this signature in database GPG Key ID: 943B179E15D3B22A
2 changed files with 13 additions and 1 deletions
  1. +3
    -0
      CHANGELOG.md
  2. +10
    -1
      octodns/manager.py

+ 3
- 0
CHANGELOG.md View File

@ -25,6 +25,9 @@
* Add --all option to octodns-validate to enable showing all record validation
errors (as warnings) rather than exiting on the first. Exit code is non-zero
when there are any validation errors.
* New `post_processors` manager configuration parameter to add global processors
that run AFTER zone-specific processors. This should allow more complete
control over when processors are run.
## v1.0.0 - 2023-07-30 - The One


+ 10
- 1
octodns/manager.py View File

@ -114,6 +114,11 @@ class Manager(object):
self.global_processors = manager_config.get('processors', [])
self.log.info('__init__: global_processors=%s', self.global_processors)
self.global_post_processors = manager_config.get('post_processors', [])
self.log.info(
'__init__: global_post_processors=%s', self.global_post_processors
)
providers_config = self.config['providers']
self.providers = self._config_providers(providers_config)
@ -634,7 +639,11 @@ class Manager(object):
try:
collected = []
for processor in self.global_processors + processors:
for processor in (
self.global_processors
+ processors
+ self.global_post_processors
):
collected.append(self.processors[processor])
processors = collected
except KeyError:


Loading…
Cancel
Save