Skip to content

Instantly share code, notes, and snippets.

@ganeshrn
Created September 24, 2020 05:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ganeshrn/89137bf3303aaea3e8907e1b638f0eba to your computer and use it in GitHub Desktop.
Save ganeshrn/89137bf3303aaea3e8907e1b638f0eba to your computer and use it in GitHub Desktop.
community.yang.configure example
- name: configure interface using structured data in JSON format
community.yang.configure:
config: "{{ lookup('file', './iosxr01/config/interfaces.json') | to_json }}"
file: "{{ playbook_dir }}/{{inventory_hostname}}/yang_files/Cisco-IOS-XR-ifmgr-cfg.yang"
search_path: "{{ playbook_dir }}/{{inventory_hostname}}/yang_files"
register: result
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment