Set the sent_topics for openqa

Signed-off-by: Aurélien Bompard <aurelien@bompard.org>
This commit is contained in:
Aurélien Bompard
2023-05-15 15:06:01 +02:00
parent 11b3c5c935
commit 4d36f9ed50
3 changed files with 13 additions and 28 deletions

View File

@@ -15,8 +15,8 @@
#
# Optional parameters:
#
# - write_queues (list): A list of queue name prefixes to which the user will
# be allowed to publish.
# - sent_topics (str): A regular expression that must match the topic when a
# message is published by this user.
# - thresholds (dict): A dictionary with two keys: "warning" and "critical".
# The values are numbers. Generate an alert in Nagios if
# the number of messages go above these values.
@@ -26,6 +26,7 @@
that:
- "queue_name.startswith(username)"
fail_msg: "Your queue name must be prefixed with your username"
when: username is defined
tags:
- fedora-messaging
- rabbitmq_cluster
@@ -34,6 +35,7 @@
name: rabbit/user
vars:
publish_only: false
when: username is defined
tags:
- fedora-messaging
- rabbitmq_cluster

View File

@@ -8,6 +8,11 @@
#
# - username (str): the username to create in RabbitMQ, which should match the
# CN of the certificate.
#
# Optional parameters:
#
# - sent_topics (str): A regular expression that must match the topic when a
# message is published by this user.
# See https://www.rabbitmq.com/access-control.html#permissions for details on
# the RabbitMQ permissions configuration.
@@ -15,6 +20,7 @@
- name: Validate username {{ username }}
assert:
that:
- username is defined
- username != "admin"
- username != "guest"
- username != "nagios-monitoring"