1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-15 18:50:09 +03:00

F : Generalisation of vxlan playbook ()

This commit is contained in:
Alejandro Huertas Herrero 2019-02-13 18:35:15 +01:00 committed by Tino Vázquez
parent 633b9616cc
commit e04ec57f9d
3 changed files with 5 additions and 4 deletions
share/oneprovision
ansible
inventories/static_vxlan/group_vars
static_vxlan.yml
templates

@ -20,8 +20,9 @@ iptables_base_rules_strict: false
# Parameters for static VXLAN connections between provisioned hosts
opennebula_p2p_vxlan_bridge: vxbr100
opennebula_p2p_vxlan_phydev: bond0:0
opennebula_p2p_vxlan_phydev: "{{ ansible_interfaces | sort | select('in', ['bond0_0', 'eth0']) | first | replace('_', ':') }}"
ansible_phydev: "ansible_{{ ansible_interfaces | sort | select('in', ['bond0_0', 'eth0']) | first }}"
opennebula_p2p_vxlan_vxlan_vni: 100
opennebula_p2p_vxlan_vxlan_dev: vxlan100
opennebula_p2p_vxlan_vxlan_local_ip: '{{ ansible_facts["bond0_0"]["ipv4"]["address"] }}'
opennebula_p2p_vxlan_remotes: "{{ groups['nodes'] | map('extract', hostvars, ['ansible_bond0_0', 'ipv4', 'address']) | list }}"
opennebula_p2p_vxlan_vxlan_local_ip: '{{ ansible_facts[opennebula_p2p_vxlan_phydev | replace(":", "_")]["ipv4"]["address"] }}'
opennebula_p2p_vxlan_remotes: "{{ groups['nodes'] | map('extract', hostvars, [ansible_phydev, 'ipv4', 'address']) | list }}"

@ -1,6 +1,6 @@
---
version: 2
playbook: vxlan_packet
playbook: static_vxlan
networks:
- name: "nat"