Merge "Fix RPM warnings, cleanup"

This commit is contained in:
Jenkins 2017-06-29 16:03:01 +00:00 committed by Gerrit Code Review
commit 71168795b2

View File

@ -17,8 +17,7 @@
# so we skip this task in the ansible-lint check by using the # so we skip this task in the ansible-lint check by using the
# 'skip_ansible_lint' tag # 'skip_ansible_lint' tag
- name: Get version of installed RabbitMQ package (deb) - name: Get version of installed RabbitMQ package (deb)
shell: | shell: "dpkg -l | grep rabbitmq-server"
dpkg -l | grep rabbitmq-server
failed_when: false failed_when: false
register: installed_rabbitmq_deb register: installed_rabbitmq_deb
when: when:
@ -33,8 +32,9 @@
# so we skip this task in the ansible-lint check by using the # so we skip this task in the ansible-lint check by using the
# 'skip_ansible_lint' tag # 'skip_ansible_lint' tag
- name: Get version of installed RabbitMQ package (rpm) - name: Get version of installed RabbitMQ package (rpm)
shell: | shell: "rpm -qa | grep rabbitmq-server"
rpm -qa | grep rabbitmq-server args:
warn: no
failed_when: false failed_when: false
register: installed_rabbitmq_rpm register: installed_rabbitmq_rpm
when: when:
@ -49,7 +49,9 @@
- name: Register a fact for the installed RabbitMQ version - name: Register a fact for the installed RabbitMQ version
set_fact: set_fact:
installed_rabbitmq: "{{ item }}" installed_rabbitmq: "{{ item }}"
when: not item | skipped and item | changed when:
- not item | skipped
- item | changed
with_items: with_items:
- "{{ installed_rabbitmq_deb }}" - "{{ installed_rabbitmq_deb }}"
- "{{ installed_rabbitmq_rpm }}" - "{{ installed_rabbitmq_rpm }}"