Skip to content

eos_cli_config_gen

Note

Always use the FQCN (Fully Qualified Collection Name) arista.avd.eos_cli_config_gen when using this plugin.

Generate AVD EOS device configurations and documentations

Synopsis

The arista.avd.eos_cli_config_gen module is an Ansible Action Plugin providing the following capabilities:

  • Generates device configuration and saves it to file
  • Optionally generates device documentation and saves it to file

Note: Input validation is performed by the arista.avd.validate_inputs plugin, which must be run before this plugin.

Parameters

Argument Type Required Default Value Restrictions Description
config_filename str optional None - The path to save the generated config to. Required if generate_device_config is true.
documentation_filename str optional None - The path to save the generated documentation. Required if generate_device_doc is true.
generate_device_config bool optional True - Flag to generate the device configuration.
generate_device_doc bool optional True - Flag to generate the device documentation.
device_doc_toc bool optional True - Flag to generate the table of content for the device documentation.
cprofile_file str False None - Filename for storing cprofile data used to debug performance issues.
Running cprofile will slow down performance in it self, so only set this while troubleshooting.

Examples

---
- name: Generate EOS intended configuration and device documentation
  arista.avd.eos_cli_config_gen:
    config_filename: "{{ eos_config_dir }}/{{ inventory_hostname }}.cfg"
    documentation_filename: "{{ devices_dir }}/{{ inventory_hostname }}.md"
  delegate_to: localhost

- name: Generate device documentation only
  arista.avd.eos_cli_config_gen:
    config_filename: "{{ eos_config_dir }}/{{ inventory_hostname }}.cfg"
    documentation_filename: "{{ devices_dir }}/{{ inventory_hostname }}.md"
    generate_device_config: false
    device_doc_toc: true
  delegate_to: localhost

Authors

  • Arista Ansible Team (@aristanetworks)