Browse Source

Merge remote-tracking branch 'origin/master' into idna-internally

pull/922/head
Ross McFarland 3 years ago
parent
commit
cda6ef3909
No known key found for this signature in database GPG Key ID: 943B179E15D3B22A
2 changed files with 43 additions and 2 deletions
  1. +2
    -2
      CHANGELOG.md
  2. +41
    -0
      octodns/processor/filter.py

+ 2
- 2
CHANGELOG.md View File

@ -1,8 +1,8 @@
## v0.9.18 - 2022-09-14 - Subzone handling
## v0.9.18 - 2022-08-14 - Subzone handling
* Fixed issue with sub-zone handling introduced in 0.9.18 * Fixed issue with sub-zone handling introduced in 0.9.18
## v0.9.18 - 2022-09-09 - Internationalization
## v0.9.18 - 2022-08-09 - Internationalization
* Added octodns.idna idna_encode/idna_decode helpers, providers will need to * Added octodns.idna idna_encode/idna_decode helpers, providers will need to
individually add support via these helpers though :-/ individually add support via these helpers though :-/


+ 41
- 0
octodns/processor/filter.py View File

@ -13,6 +13,27 @@ from .base import BaseProcessor
class TypeAllowlistFilter(BaseProcessor): class TypeAllowlistFilter(BaseProcessor):
'''Only manage records of the specified type(s).
Example usage:
processors:
only-a-and-aaaa:
class: octodns.processor.filter.TypeRejectlistFilter
rejectlist:
- A
- AAAA
zones:
exxampled.com.:
sources:
- config
processors:
- only-a-and-aaaa
targets:
- ns1
'''
def __init__(self, name, allowlist): def __init__(self, name, allowlist):
super(TypeAllowlistFilter, self).__init__(name) super(TypeAllowlistFilter, self).__init__(name)
self.allowlist = set(allowlist) self.allowlist = set(allowlist)
@ -29,6 +50,26 @@ class TypeAllowlistFilter(BaseProcessor):
class TypeRejectlistFilter(BaseProcessor): class TypeRejectlistFilter(BaseProcessor):
'''Ignore records of the specified type(s).
Example usage:
processors:
ignore-cnames:
class: octodns.processor.filter.TypeRejectlistFilter
rejectlist:
- CNAME
zones:
exxampled.com.:
sources:
- config
processors:
- ignore-cnames
targets:
- route53
'''
def __init__(self, name, rejectlist): def __init__(self, name, rejectlist):
super(TypeRejectlistFilter, self).__init__(name) super(TypeRejectlistFilter, self).__init__(name)
self.rejectlist = set(rejectlist) self.rejectlist = set(rejectlist)


Loading…
Cancel
Save