diff options
author | Markos Chandras <mchandras@suse.de> | 2018-08-31 10:34:56 +0100 |
---|---|---|
committer | Markos Chandras <mchandras@suse.de> | 2018-09-04 07:26:45 +0000 |
commit | 0701ea9d39e4bcbf7cb7733cadfdab79b6e266b2 (patch) | |
tree | b765e2c4e8a399a121683618471bf476a03fbd2e | |
parent | 933c7a0f36c970d24954b9ba1552a29a75b43976 (diff) |
xci: infra: bifrost: Allow DNS overrides
Deployers may want to use a different DNS server so allow them to
override the ipv4_nameserver option. If the variable is not set,
then we use the libvirt DNS if we are behind a proxy, otherwise
we default to the Google DNS.
Change-Id: I96cf63758902d4aae3d155b2e8beef650449ebc9
Signed-off-by: Markos Chandras <mchandras@suse.de>
-rw-r--r-- | xci/infra/bifrost/playbooks/opnfv-virtual.yml | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/xci/infra/bifrost/playbooks/opnfv-virtual.yml b/xci/infra/bifrost/playbooks/opnfv-virtual.yml index 68d76cfc..abac7ba2 100644 --- a/xci/infra/bifrost/playbooks/opnfv-virtual.yml +++ b/xci/infra/bifrost/playbooks/opnfv-virtual.yml @@ -128,10 +128,6 @@ setup: delegate_to: opnfv delegate_facts: False - - name: "Override default bifrost DNS if we are behind a proxy" - set_fact: - ipv4_nameserver: "192.168.122.1" - when: lookup('env','http_proxy') != '' - name: Find network interface in the OPNFV node set_fact: network_interface: "{{ ansible_default_ipv4.interface }}" @@ -147,6 +143,8 @@ - import_role: name: bifrost-configdrives-dynamic private: True + vars: + ipv4_namesever: "{{ ipv4_nameserver | ((lookup('env','http_proxy') != '') | ternary('192.168.122.1', '8.8.8.8')) }}" delegate_to: opnfv - import_role: name: bifrost-deploy-nodes-dynamic |