|
| 1 | +--- |
| 2 | +- name: Generate access point location playbook configuration from Cisco Catalyst Center |
| 3 | + hosts: localhost |
| 4 | + connection: local |
| 5 | + gather_facts: false |
| 6 | + vars_files: |
| 7 | + - "credentials.yml" |
| 8 | + tasks: |
| 9 | + # Example 1: Generate all access point location configurations |
| 10 | + - name: Generate complete access point location configuration |
| 11 | + cisco.dnac.accesspoint_location_playbook_config_generator: |
| 12 | + dnac_host: "{{ dnac_host }}" |
| 13 | + dnac_username: "{{ dnac_username }}" |
| 14 | + dnac_password: "{{ dnac_password }}" |
| 15 | + dnac_verify: "{{ dnac_verify }}" |
| 16 | + dnac_port: "{{ dnac_port }}" |
| 17 | + dnac_version: "{{ dnac_version }}" |
| 18 | + dnac_debug: "{{ dnac_debug }}" |
| 19 | + dnac_log: true |
| 20 | + dnac_log_level: DEBUG |
| 21 | + dnac_api_task_timeout: 1000 |
| 22 | + dnac_task_poll_interval: 1 |
| 23 | + state: gathered |
| 24 | + file_path: "tmp/accesspoint_location_workflow_playbook.yml" |
| 25 | + file_mode: append |
| 26 | + |
| 27 | + # Example 2: Generate access point location configurations by sites |
| 28 | + - name: Generate access point location configurations by sites |
| 29 | + cisco.dnac.accesspoint_location_playbook_config_generator: |
| 30 | + dnac_host: "{{ dnac_host }}" |
| 31 | + dnac_username: "{{ dnac_username }}" |
| 32 | + dnac_password: "{{ dnac_password }}" |
| 33 | + dnac_verify: "{{ dnac_verify }}" |
| 34 | + dnac_port: "{{ dnac_port }}" |
| 35 | + dnac_version: "{{ dnac_version }}" |
| 36 | + dnac_debug: "{{ dnac_debug }}" |
| 37 | + dnac_log: true |
| 38 | + dnac_log_level: DEBUG |
| 39 | + dnac_api_task_timeout: 1000 |
| 40 | + dnac_task_poll_interval: 1 |
| 41 | + state: gathered |
| 42 | + file_path: "tmp/accesspoint_location_workflow_playbook_site_base.yml" |
| 43 | + file_mode: "append" |
| 44 | + config: |
| 45 | + global_filters: |
| 46 | + site_list: |
| 47 | + - Global/USA/SAN JOSE/SJ_BLD23/FLOOR1 |
| 48 | + - Global/USA/SAN JOSE/SJ_BLD23/FLOOR2 |
| 49 | + - Global/USA/SAN JOSE/SJ_BLD23/FLOOR4 |
| 50 | + |
| 51 | + # Example 3: Generate access point location configurations by planned APs |
| 52 | + - name: Generate access point location configurations by planned APs |
| 53 | + cisco.dnac.accesspoint_location_playbook_config_generator: |
| 54 | + dnac_host: "{{ dnac_host }}" |
| 55 | + dnac_username: "{{ dnac_username }}" |
| 56 | + dnac_password: "{{ dnac_password }}" |
| 57 | + dnac_verify: "{{ dnac_verify }}" |
| 58 | + dnac_port: "{{ dnac_port }}" |
| 59 | + dnac_version: "{{ dnac_version }}" |
| 60 | + dnac_debug: "{{ dnac_debug }}" |
| 61 | + dnac_log: true |
| 62 | + dnac_log_level: DEBUG |
| 63 | + dnac_api_task_timeout: 1000 |
| 64 | + dnac_task_poll_interval: 1 |
| 65 | + state: gathered |
| 66 | + file_path: "tmp/accesspoint_location_workflow_playbook_PAP_base.yml" |
| 67 | + file_mode: "append" |
| 68 | + config: |
| 69 | + global_filters: |
| 70 | + planned_accesspoint_list: |
| 71 | + - ap_test_auto-1 |
| 72 | + - ap_test_auto-3 |
| 73 | + |
| 74 | + # Example 4: Generate access point location configurations by real APs |
| 75 | + - name: Generate access point location configurations by real APs |
| 76 | + cisco.dnac.accesspoint_location_playbook_config_generator: |
| 77 | + dnac_host: "{{ dnac_host }}" |
| 78 | + dnac_username: "{{ dnac_username }}" |
| 79 | + dnac_password: "{{ dnac_password }}" |
| 80 | + dnac_verify: "{{ dnac_verify }}" |
| 81 | + dnac_port: "{{ dnac_port }}" |
| 82 | + dnac_version: "{{ dnac_version }}" |
| 83 | + dnac_debug: "{{ dnac_debug }}" |
| 84 | + dnac_log: true |
| 85 | + dnac_log_level: DEBUG |
| 86 | + dnac_api_task_timeout: 1000 |
| 87 | + dnac_task_poll_interval: 1 |
| 88 | + state: gathered |
| 89 | + file_path: "tmp/accesspoint_location_workflow_playbook_real_ap_base.yml" |
| 90 | + file_mode: "append" |
| 91 | + config: |
| 92 | + global_filters: |
| 93 | + real_accesspoint_list: |
| 94 | + - AP687D.B402.1614-AP-Test6 |
| 95 | + - Cisco_9120AXE_IP4-01-Test2 |
| 96 | + |
| 97 | + # Example 5: Generate access point location configurations by access point models |
| 98 | + - name: Generate access point location configurations by AP models |
| 99 | + cisco.dnac.accesspoint_location_playbook_config_generator: |
| 100 | + dnac_host: "{{ dnac_host }}" |
| 101 | + dnac_username: "{{ dnac_username }}" |
| 102 | + dnac_password: "{{ dnac_password }}" |
| 103 | + dnac_verify: "{{ dnac_verify }}" |
| 104 | + dnac_port: "{{ dnac_port }}" |
| 105 | + dnac_version: "{{ dnac_version }}" |
| 106 | + dnac_debug: "{{ dnac_debug }}" |
| 107 | + dnac_log: true |
| 108 | + dnac_log_level: DEBUG |
| 109 | + dnac_api_task_timeout: 1000 |
| 110 | + dnac_task_poll_interval: 1 |
| 111 | + state: gathered |
| 112 | + file_path: "tmp/accesspoint_location_workflow_playbook_accesspoint_model_base.yml" |
| 113 | + file_mode: "overwrite" |
| 114 | + config: |
| 115 | + global_filters: |
| 116 | + accesspoint_model_list: |
| 117 | + - AP9120E |
| 118 | + - CW9172I |
| 119 | + |
| 120 | + # Example 6: Generate access point location configurations by MAC addresses |
| 121 | + - name: Generate access point location configurations by MAC addresses |
| 122 | + cisco.dnac.accesspoint_location_playbook_config_generator: |
| 123 | + dnac_host: "{{ dnac_host }}" |
| 124 | + dnac_username: "{{ dnac_username }}" |
| 125 | + dnac_password: "{{ dnac_password }}" |
| 126 | + dnac_verify: "{{ dnac_verify }}" |
| 127 | + dnac_port: "{{ dnac_port }}" |
| 128 | + dnac_version: "{{ dnac_version }}" |
| 129 | + dnac_debug: "{{ dnac_debug }}" |
| 130 | + dnac_log: true |
| 131 | + dnac_log_level: DEBUG |
| 132 | + dnac_api_task_timeout: 1000 |
| 133 | + dnac_task_poll_interval: 1 |
| 134 | + state: gathered |
| 135 | + file_path: "tmp/accesspoint_location_workflow_playbook_mac_address_base.yml" |
| 136 | + file_mode: "overwrite" |
| 137 | + config: |
| 138 | + global_filters: |
| 139 | + mac_address_list: |
| 140 | + - cc:6e:2a:e1:02:40 |
0 commit comments