# {{ ansible_managed }}

[DEFAULT]
enabled_hardware_types: {{ kolla_ironic_enabled_hardware_types | join(',') }}

{# Add configuration of enabled and default dynamic driver interfaces. #}
{% set interfaces=['boot', 'bios', 'console', 'deploy', 'inspect', 'management',
                   'network', 'power', 'raid', 'rescue', 'storage', 'vendor'] %}
{% for interface in interfaces %}
{% if hostvars[inventory_hostname]['kolla_ironic_enabled_' ~ interface ~ '_interfaces'] | default %}
{{ 'enabled_' ~ interface ~ '_interfaces' }} = {{ hostvars[inventory_hostname]['kolla_ironic_enabled_' ~ interface ~ '_interfaces'] | join(',') }}
{% endif %}
{% if hostvars[inventory_hostname]['kolla_ironic_default_' ~ interface ~ '_interface'] | default %}
{{ 'default_' ~ interface ~ '_interface' }} = {{ hostvars[inventory_hostname]['kolla_ironic_default_' ~ interface ~ '_interface'] }}
{% endif %}
{% endfor %}

[agent]
deploy_logs_local_path = /var/log/kolla/ironic/deploy

[deploy]
{% if kolla_ironic_default_boot_option %}
default_boot_option = {{ kolla_ironic_default_boot_option }}
{% endif %}

[neutron]
cleaning_network = {{ kolla_ironic_cleaning_network }}
provisioning_network = {{ kolla_ironic_provisioning_network }}

[pxe]
{% if kolla_ironic_pxe_append_params %}
pxe_append_params = {{ kolla_ironic_pxe_append_params | join(' ') }}
{% endif %}

{% raw %}
tftp_server = {{ hostvars[inventory_hostname].ansible_facts[api_interface | replace('-', '_')]['ipv4']['address'] }}
{% endraw %}

{% if kolla_extra_ironic %}
#######################
# Extra configuration
#######################

{{ kolla_extra_ironic }}
{% endif %}
