-
Notifications
You must be signed in to change notification settings - Fork 544
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DNS records from DNSAAS. #2289
DNS records from DNSAAS. #2289
Conversation
|
||
|
||
DNS_AUTO_PTR_ALWAYS = 2 | ||
DNS_AUTO_PTR_NEVER = 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Django settings?
please add basic documentation (docs) for dnsaas integration - possible settings. Put a note here, that this is not transaction-safe, since it's communicating with external system through the api. |
- ``ENABLE_DNSAAS_INTEGRATION`` - set to True if you want to enable DNSaaS integration | ||
- ``DNSAAS_URL`` - Url to DNSAAS | ||
- ``DNSAAS_TOKEN`` - API Token to DNSAAS | ||
- ``DNS_AUTO_PTR_ALWAYS`` - DNSAAS auto_ptr value, default is 2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DNS_AUTO_PTR_ALWAYS
-> DNSAAS_AUTO_PTR_ALWAYS
?
logger = logging.getLogger(__name__) | ||
|
||
|
||
def get_api_kwargs(url, data=None, headers=None): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please move all *_api_*
and *_dns_*
method to class and separated module like dnsass.py
Added optional DNS feature to data center assets. See: https://github.com/allegro/django-powerdns-dnssec
if result: | ||
return result[0]['url'] | ||
|
||
def create_dns_records(self, record): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
create_dns_records or create_dns_record ?
Change method name in DNSAAS api
…d in view * Now you could use `skip_first` param in cache decorator - when set to True, first param (usually class instance a.k.a self) will not be used to calculate hash of params * dnsview not checks if dnsaas integration is enabled
Added `skip_first` to cache and check if dnsaas integration is enabled in view
🆗 |
1 similar comment
🆗 |
Added optional DNS feature to data center assets.
See: https://github.com/allegro/django-powerdns-dnssec