diff options
Diffstat (limited to 'tasks')
-rw-r--r-- | tasks/debian.yml | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/tasks/debian.yml b/tasks/debian.yml index b25d39b..f35bf55 100644 --- a/tasks/debian.yml +++ b/tasks/debian.yml | |||
@@ -9,14 +9,21 @@ | |||
9 | apt_repository: | 9 | apt_repository: |
10 | repo: "{{ rabbitmq_debian_repo }}" | 10 | repo: "{{ rabbitmq_debian_repo }}" |
11 | state: present | 11 | state: present |
12 | register: "rabbitmq_repo_added" | ||
13 | become: true | 12 | become: true |
14 | 13 | ||
15 | - name: debian | updating apt cache | 14 | - name: debian | add Rabbitmq erlang repo key |
16 | apt: | 15 | apt_key: |
17 | update_cache: yes | 16 | url: https://bintray.com/user/downloadSubjectPublicKey?username=rabbitmq-erlang |
17 | state: present | ||
18 | become: true | ||
19 | when: rabbitmq_debian_erlang_from_rabbit | ||
20 | |||
21 | - name: debian | add Rabbitmq erlang repo | ||
22 | apt_repository: | ||
23 | repo: deb https://dl.bintray.com/rabbitmq-erlang/debian {{ ansible_distribution_release }} erlang | ||
24 | state: present | ||
18 | become: true | 25 | become: true |
19 | when: rabbitmq_repo_added.changed | 26 | when: rabbitmq_debian_erlang_from_rabbit |
20 | 27 | ||
21 | - name: debian | installing RabbitMQ server | 28 | - name: debian | installing RabbitMQ server |
22 | apt: | 29 | apt: |
@@ -24,7 +31,7 @@ | |||
24 | state: present | 31 | state: present |
25 | become: true | 32 | become: true |
26 | with_items: | 33 | with_items: |
27 | - rabbitmq-server | 34 | - rabbitmq-server{{ (rabbitmq_debian_version is defined) | ternary(['=',rabbitmq_debian_version] | join(''),'')}} |
28 | 35 | ||
29 | - name: debian | enabling the RabbitMQ Management Console | 36 | - name: debian | enabling the RabbitMQ Management Console |
30 | rabbitmq_plugin: | 37 | rabbitmq_plugin: |