Skip to content
Snippets Groups Projects
Commit 1c39247c authored by Kamil Andoniadis's avatar Kamil Andoniadis
Browse files

add default variables

parent eabe9b0e
No related branches found
No related tags found
No related merge requests found
......@@ -12,3 +12,13 @@ interface_file: '
interface_clean: True
interface_mtu: 1442
interface_mac:
interface_default_gateway:
interface_routes: []
# - gateway:
# network:
# mask:
interface_required_variables:
interface_mac: '{{ interface_mac }}'
- name: check existence of required variables
fail:
msg: interface_mac is not defined
when: not interface_mac
msg: required variable '{{ item.key }}' is undefined
when: item.value is undefined or not item.value
loop: '{{ interface_required_variables }}'
- set_fact:
interface_device: '{%- from "roles/common/templates/network.j2" import mac_to_interface with context -%}
......@@ -11,3 +13,4 @@
when: interface_clean is defined and interface_clean
- include: interface.yml
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment