Greenwave: use the rabbit/queue role to create the greenwave queue

Signed-off-by: Clement Verna <cverna@tutanota.com>
This commit is contained in:
Clement Verna 2019-04-03 09:46:35 +02:00
parent 45d528f279
commit 58bf263346

View file

@ -8,21 +8,16 @@
- "/srv/private/ansible/vars.yml"
- /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml
tasks:
- name: Create the user in RabbitMQ
delegate_to: "rabbitmq01{{ env_suffix }}.phx2.fedoraproject.org"
rabbitmq_user:
user: "greenwave{{ env_suffix }}"
vhost: "/pubsub"
read_priv: "amq\\.topic" # Publish only, no reading
write_priv: "amq\\.topic"
configure_priv: "^$" # No configuration permissions
state: present
tags:
- config
- fedora-messaging
roles:
- role: rabbit/queue
username: greenwave{{ env_suffix }}
queue_name: greenwave
routing_keys:
- "org.fedoraproject.*.taskotron.result.new"
- "org.fedoraproject.*.waiver.new"
# The openshift/project role breaks if the project already exists:
# https://pagure.io/fedora-infrastructure/issue/6404
- role: openshift/project