skip to Main Content

RabbitMQ in Docker throws exception when I try to connect from java with custom port

I run RabbitMQ in docker using this command: docker run --rm -it --hostname my-rabbit -p 15672:15672 -p 5672:5672 rabbitmq:3-management It works and I can connect to RabitMq from java: ConnectionFactory factory = new ConnectionFactory(); factory.setUsername("guest"); factory.setPassword("guest"); Connection connection = factory.newConnection("http://localhost:5672");…

VIEW QUESTION

RabbitMQ fails to boot from docker-compose – Ubuntu

Im trying to set up rabbitmq instance from docker-compose command. My docker compose yaml version: '3.8' services: rabbitmq: image: rabbitmq:3-management hostname: rabbit container_name: 'rabbitmq' volumes: - ./etc/rabbitmq.conf:/etc/rabbitmq/rabbitmq.conf - ./data:/var/lib/rabbitmq/mnesia/rabbit@rabbit - ./logs:/var/log/rabbitmq/log - ./etc/ssl/CERT_LAB_CA.pem:/etc/rabbitmq/ssl/cacert.pem - ./etc/ssl/CERT_LAB_RABBITMQ.pem:/etc/rabbitmq/ssl/cert.pem - ./etc/ssl/KEY_LAB_RABBITMQ.pem:/etc/rabbitmq/ssl/key.pem ports: - 5672:5672…

VIEW QUESTION
Back To Top
Search