Implement has_debug_instance and use to lower ttl

dehydrated
Felix Stupp 4 years ago
parent 0b03f87319
commit 889a493fdd
Signed by: zocker
GPG Key ID: 93E1BD26F6B02FB7

@ -31,7 +31,8 @@ backup_mysql_database_scripts_directory: "{{ backup_scripts_directory }}/mysql_d
# If debug mode is disabled, the compatibility to the "debug domain" will be lost and the original's instance DNS config will be overwritten # If debug mode is disabled, the compatibility to the "debug domain" will be lost and the original's instance DNS config will be overwritten
# Other variables will need to be adjusted if both instances run on the same server # Other variables will need to be adjusted if both instances run on the same server
is_debug_instance: no is_debug_instance: no
delete_debug_dns_entries: "{{ not is_debug_instance }}" has_debug_instance: "{{ is_debug_instance }}"
delete_debug_dns_entries: "{{ not has_debug_instance }}"
debug_domain: "debug-instance.{{ domain }}" # used if is_debug_instance / on "debug mode", should only prefix domain debug_domain: "debug-instance.{{ domain }}" # used if is_debug_instance / on "debug mode", should only prefix domain
effective_domain: "{{ is_debug_instance | ternary(debug_domain, domain) }}" effective_domain: "{{ is_debug_instance | ternary(debug_domain, domain) }}"
@ -52,6 +53,7 @@ global_dns_session_key_path: "/var/run/named/session.key"
global_dns_session_key_algorithm: "hmac-sha512" global_dns_session_key_algorithm: "hmac-sha512"
global_dns_update_key_algorithm: "ED25519" global_dns_update_key_algorithm: "ED25519"
global_dns_ttl: "{{ 60 * 60 }}" # default if omitted in all cases global_dns_ttl: "{{ 60 * 60 }}" # default if omitted in all cases
global_dns_debug_ttl: "{{ 60 }}" # mostly used if has_debug_instance to allow short transfer times
global_ssh_key_directory: "{{ global_public_key_directory }}/ssh" global_ssh_key_directory: "{{ global_public_key_directory }}/ssh"
global_ssh_host_key_directory: "{{ global_ssh_key_directory }}/hosts" global_ssh_host_key_directory: "{{ global_ssh_key_directory }}/hosts"

@ -7,6 +7,6 @@
dns_zone_domain: "{{ lookup('pipe', global_public_key_directory|quote + '/dns_zone.py ' + domain|quote) }}" # domain of dns zone dns_zone_domain: "{{ lookup('pipe', global_public_key_directory|quote + '/dns_zone.py ' + domain|quote) }}" # domain of dns zone
dns_system_domain: "{{ lookup('file', global_dns_list_directory + '/' + dns_zone_domain) }}" # domain of dns authority server dns_system_domain: "{{ lookup('file', global_dns_list_directory + '/' + dns_zone_domain) }}" # domain of dns authority server
ttl_default: "{{ global_dns_ttl }}" # TTL for all entries where none was given ttl_default: "{{ has_debug_instance | ternary(global_dns_debug_ttl, global_dns_ttl) }}" # TTL for all entries where none was given
# entries (example: [{domain: "example.com.", ttl: 86400, class: "IN", type: "A", data: "0.0.0.0"},"example.com. IN AAAA ::",…], type/data or raw required, class will be ignored) # entries (example: [{domain: "example.com.", ttl: 86400, class: "IN", type: "A", data: "0.0.0.0"},"example.com. IN AAAA ::",…], type/data or raw required, class will be ignored)

Loading…
Cancel
Save