rabbitmq_server: there's no system change on a package query
There doesn't seem to be a need to check for changed either, and it's easier to read "when: item is not skipped" Change-Id: I7d8300bcdf0caf24485ce2edc5f2be2672369d2f
This commit is contained in:
parent
72c88258b2
commit
7aa3d4a9ca
@ -18,6 +18,7 @@
|
||||
# 'skip_ansible_lint' tag
|
||||
- name: Get version of installed RabbitMQ package (deb)
|
||||
shell: "dpkg -l | grep rabbitmq-server"
|
||||
changed_when: false
|
||||
failed_when: false
|
||||
register: installed_rabbitmq_deb
|
||||
when:
|
||||
@ -35,6 +36,7 @@
|
||||
shell: "rpm -qa | grep rabbitmq-server"
|
||||
args:
|
||||
warn: no
|
||||
changed_when: false
|
||||
failed_when: false
|
||||
register: installed_rabbitmq_rpm
|
||||
when:
|
||||
@ -50,8 +52,7 @@
|
||||
set_fact:
|
||||
installed_rabbitmq: "{{ item }}"
|
||||
when:
|
||||
- not item is skipped
|
||||
- item is changed
|
||||
- item is not skipped
|
||||
with_items:
|
||||
- "{{ installed_rabbitmq_deb }}"
|
||||
- "{{ installed_rabbitmq_rpm }}"
|
||||
|
Loading…
Reference in New Issue
Block a user