based on that comment:
https://tracker.ceph.com/issues/67206#note-6
the address used by the endpoint is taken as the real IP address of the
host where the test script is running and not localhost.
we also changed the rabbitmq-server conf to allow "guest"
user to connect over non localhost address
Fixes: https://tracker.ceph.com/issues/67206
Signed-off-by: Yuval Lifshitz <ylifshit@ibm.com>
(cherry picked from commit
cdd75b499f7fe944906d863b9933e8d3aff95e5f)
Conflicts:
qa/tasks/rabbitmq.py
src/test/rgw/bucket_notification/test_bn.py
'sudo', 'chkconfig', 'rabbitmq-server', 'on'
],
)
+
+ ctx.cluster.only(client).run(args=[
+ 'echo', 'loopback_users.guest = false', run.Raw('|'), 'sudo', 'tee', '-a', '/etc/rabbitmq/rabbitmq.conf'
+ ],
+ )
ctx.cluster.only(client).run(args=[
'sudo', '/sbin/service', 'rabbitmq-server', 'start'
def get_ip():
- return 'localhost'
-
-
-def get_ip_http():
s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
try:
# address should not be reachable
host = get_ip()
if endpoint_type == 'http':
# create random port for the http server
- host = get_ip_http()
+ host = get_ip()
port = random.randint(10000, 20000)
# start an http server in a separate thread
receiver = StreamingHTTPServer(host, port, num_workers=10)