Allow to add extra records to /etc/hosts
Add variable, that would allow to provide extra records for /etc/hosts file. That might be useful for ppl who still have not adopted proper DNS or want to do DNS RR, but not for internal VIP and manage internal VIP with /etc/hosts file, where each host group would resolve FQDN to a local address. Change-Id: I89f8cdebf9322c0451b5600b073c82b7773af164
This commit is contained in:
parent
010b8377ed
commit
f26fbe4c6a
|
@ -38,6 +38,12 @@ openstack_hosts_package_state: "latest"
|
|||
openstack_host_manage_hosts_file: true
|
||||
## Enable/disable /etc/hosts file management on OSA deploy host
|
||||
openstack_host_manage_deploy_hosts_file: true
|
||||
## Provide extra records to /etc/hosts file that would be added
|
||||
## to all hosts, if openstack_host_manage_hosts_file is true
|
||||
## Example:
|
||||
## openstack_host_custom_hosts_records:
|
||||
## - '192.168.1.1 my.fqdn'
|
||||
openstack_host_custom_hosts_records: []
|
||||
|
||||
## kernel modules for specific group hosts
|
||||
openstack_host_specific_kernel_modules: []
|
||||
|
|
|
@ -0,0 +1,7 @@
|
|||
---
|
||||
features:
|
||||
- |
|
||||
Added variable ``openstack_host_custom_hosts_records`` that allows
|
||||
deployer to add custom records to /etc/hosts file. It's structure
|
||||
a simple list where each element is a string wich should be placed
|
||||
to /etc/hosts.
|
|
@ -17,7 +17,7 @@
|
|||
run_once: true
|
||||
set_fact:
|
||||
_etc_hosts_content: |-
|
||||
{% set records = [] %}
|
||||
{% set records = openstack_host_custom_hosts_records %}
|
||||
{% for item in groups['all'] %}
|
||||
{% set record = [] %}
|
||||
{% set _target_rfc_name = item|replace('_', '-') %}
|
||||
|
|
Loading…
Reference in New Issue