Kaynağa Gözat

Merge pull request #639 from sakshiarora13/devel

Fix device inventory template failure for ethernet switches
Sujit Jadhav 3 yıl önce
ebeveyn
işleme
6cb8087e90

+ 7 - 1
control_plane/roles/collect_device_info/files/create_inventory.yml

@@ -119,6 +119,12 @@
       when: "'$ANSIBLE_VAULT;' in config_content.stdout"
       run_once: true
 
+    - name: Install paramiko
+      command: pip3 install paramiko -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
+      delegate_to: localhost
+      run_once: true
+      changed_when: false
+
     - name: Initialize variables
       set_fact:
         idrac_inventory_status: false
@@ -366,4 +372,4 @@
         - name: Failed while adding device to powervault_me4_inventory
           debug:
             msg: "{{ powervault_me4_fail_msg }}"
-      when: powervault_me4_status
+      when: powervault_me4_status

+ 2 - 1
control_plane/roles/network_ethernet/tasks/pre_requisites.yml

@@ -16,6 +16,7 @@
 - name: Install paramiko
   command: pip3 install paramiko -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
   delegate_to: localhost
+  run_once: true
   changed_when: false
 
 - name: Check if ethernet_tor_vars.yml exists
@@ -71,4 +72,4 @@
         success_msg: "{{ success_msg_save_config }}"
         fail_msg: "{{ fail_msg_save_config }}"
 
-  when: "'S3' not in model_type and 'S4' not in model_type"
+  when: "'S3' not in model_type and 'S4' not in model_type"