Преглед изворни кода

Adding assert to check for python-passlib on control host

ewolinetz пре 8 година
родитељ
комит
86e4c27bb2
1 измењених фајлова са 8 додато и 0 уклоњено
  1. 8 0
      roles/openshift_metrics/tasks/main.yaml

+ 8 - 0
roles/openshift_metrics/tasks/main.yaml

@@ -1,4 +1,12 @@
 ---
 ---
+- local_action: shell rpm -q python-passlib || echo not installed
+  register: passlib_result
+
+- name: Check that python-passlib is available on the control host
+  assert:
+    that:
+      - "'not installed' not in passlib_result.stdout"
+    msg: "python-passlib rpm must be installed on control host"
 
 
 - name: Set default image variables based on deployment_type
 - name: Set default image variables based on deployment_type
   include_vars: "{{ item }}"
   include_vars: "{{ item }}"