Skip to content

Latest commit

 

History

History

rabbitmq

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 

RUN

Simple

docker run --rm -it rabbitmq

Advanced

docker run -d -it -p 5672:5672 -p 8080:15672 -e RABBITMQ_DEFAULT_USER=myuser -e RABBITMQ_DEFAULT_PASS=myuser_pw123! \
  -e RABBITMQ_DEFAULT_VHOST=myvhost \
  --name rabbitmq rabbitmq:3.11.5-management-alpine

Use

Spring - application.properties

spring.rabbitmq.host=127.0.0.1
spring.rabbitmq.port=5672
spring.rabbitmq.virtual-host=myvhost
spring.rabbitmq.username=myuser
spring.rabbitmq.password=myuser_pw123!

Gradle - build.gradle

dependencies {
  implementation 'org.springframework.boot:spring-boot-starter-amqp'
  testImplementation 'org.springframework.amqp:spring-rabbit-test'
}