summary |
shortlog |
log |
commit | commitdiff |
review |
tree
raw |
patch |
inline | side by side (from parent 1:
51d4443)
Change-Id: I883f3f97c2ac76471fe6fb1be48cc1fac2e26435
shell:
cmd: helm status cadvisor
register: result
shell:
cmd: helm status cadvisor
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: cAdvisor is already present
+ when: result.rc == 0
+
+- meta: end_play
+ when: result.rc == 0
- name: "Add helm repo"
command: helm repo add code-chris https://code-chris.github.io/helm-charts
- name: "Add helm repo"
command: helm repo add code-chris https://code-chris.github.io/helm-charts
shell:
cmd: helm status cadvisor
register: result
shell:
cmd: helm status cadvisor
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: cAdvisor is not present
+ when: result.rc == 2
+
+- meta: end_play
+ when: result.rc == 2
- name: "If cAdvisor present, then list helm ls"
command: helm ls
- name: "If cAdvisor present, then list helm ls"
command: helm ls
shell:
cmd: helm status mec-grafana
register: result
shell:
cmd: helm status mec-grafana
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: Grafana is already present
+ when: result.rc == 0
+
+- meta: end_play
+ when: result.rc == 0
- name: Install grafana on x86_64
shell:
- name: Install grafana on x86_64
shell:
shell:
cmd: helm status mec-grafana
register: result
shell:
cmd: helm status mec-grafana
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: grafana is not present
+ when: result.rc == 2
+
+- meta: end_play
+ when: result.rc == 2
- name: Uninstall grafana
shell:
- name: Uninstall grafana
shell:
shell:
cmd: which k3s
register: result
shell:
cmd: which k3s
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: k3s is already present
+ when: result.rc == 0
+
+- meta: end_play
+ when: result.rc == 0
- debug: var=ansible_host
- debug: var=ansible_host
shell:
cmd: which k3s
register: result
shell:
cmd: which k3s
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: k3s is not present
+ when: result.rc == 2
+
+- meta: end_play
+ when: result.rc == 2
-- name: debug msg
- debug:
- msg: installing k8s
+- name: Check whether k8s is already installed
+ command: which k8s
+ register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: k8s is already present
+ when: result.rc == 0
+
+- meta: end_play
+ when: result.rc == 0
- name: Install k8s
shell:
- name: Install k8s
shell:
shell:
cmd: helm status mep-prometheus
register: result
shell:
cmd: helm status mep-prometheus
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: Prpmetheus is already present
+ when: result.rc == 0
+
+- meta: end_play
+ when: result.rc == 0
- name: Install prometheus on x86_64
shell:
- name: Install prometheus on x86_64
shell:
shell:
cmd: helm status mep-prometheus
register: result
shell:
cmd: helm status mep-prometheus
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: Prometheus is not present
+ when: result.rc == 2
+
+- meta: end_play
+ when: result.rc == 2
- name: Uninstall prometheus
shell:
- name: Uninstall prometheus
shell:
shell:
cmd: kubectl get pods rabbitmq-0
register: result
shell:
cmd: kubectl get pods rabbitmq-0
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: Rabbitmq is already present
+ when: result.rc == 0
+
+- meta: end_play
+ when: result.rc == 0
- name: copy common folder to host for rabbitmg installation
copy:
- name: copy common folder to host for rabbitmg installation
copy:
shell:
cmd: kubectl get pods rabbitmq-0
register: result
shell:
cmd: kubectl get pods rabbitmq-0
register: result
+ failed_when: false
+ no_log: True
+
+- debug:
+ msg: Rabbitmq is not present
+ when: result.rc == 2
+
+- meta: end_play
+ when: result.rc == 2
- name: Uninstalling rabbitmq
shell:
- name: Uninstalling rabbitmq
shell: