Looks like it needs a full task not a delegate_to
Signed-off-by: Pierre-Yves Chibon <pingou@pingoured.fr>
This commit is contained in:
parent
c3d64514c1
commit
0e87532f03
1 changed files with 22 additions and 9 deletions
|
@ -67,15 +67,28 @@
|
||||||
- import_tasks: "{{ handlers_path }}/restart_services.yml"
|
- import_tasks: "{{ handlers_path }}/restart_services.yml"
|
||||||
|
|
||||||
# Set up for fedora-messaging
|
# Set up for fedora-messaging
|
||||||
- name: Create the user in RabbitMQ
|
- name: setup RabbitMQ
|
||||||
delegate_to: "rabbitmq01{{ env_suffix }}.phx2.fedoraproject.org"
|
hosts: rabbitmq[0]:rabbitmq-stg[0]
|
||||||
|
user: root
|
||||||
|
gather_facts: False
|
||||||
|
|
||||||
|
vars_files:
|
||||||
|
- /srv/web/infra/ansible/vars/global.yml
|
||||||
|
- "/srv/private/ansible/vars.yml"
|
||||||
|
- /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml
|
||||||
|
|
||||||
|
tasks:
|
||||||
|
- name: Create the RabbitMQ user
|
||||||
rabbitmq_user:
|
rabbitmq_user:
|
||||||
user: "pagure{{ env_suffix }}"
|
user: "pagure{{ env_suffix }}"
|
||||||
vhost: "/pubsub"
|
vhost: /pubsub
|
||||||
read_priv: "^$" # Not sending any messages, no need for read
|
read_priv: "^$"
|
||||||
write_priv: "^amq\\.topic$" # Write to queues prefixed with their name and publish to the topic exchange
|
write_priv: "amq\\.topic"
|
||||||
configure_priv: "^$" # No configuration permissions
|
configure_priv: "^$"
|
||||||
state: present
|
state: present
|
||||||
|
tags:
|
||||||
|
- config
|
||||||
|
- fedora-messaging
|
||||||
|
|
||||||
- name: setup fedmsg on pkgs
|
- name: setup fedmsg on pkgs
|
||||||
hosts: pkgs-stg:pkgs02.phx2.fedoraproject.org
|
hosts: pkgs-stg:pkgs02.phx2.fedoraproject.org
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue