1,拉取镜像
docker pull rabbitmq:3.8-management
2,运行
docker run -d --restart unless-stopped --name rabbitmq \ -p 5672:5672 -p 15672:15672 \ -e RABBITMQ_DEFAULT_USER=rabbit -e RABBITMQ_DEFAULT_PASS=Rr123456 \ -v ~/workspace-docker/rabbitmq:/var/lib/rabbitmq \ rabbitmq:3.8-management 7ea97df660c1296f5838625487e01304c0d5451c881dbd761f8f1d27fd030a91
RabbitMQ 的账号为:rabbit 密码为:Rr123456
记得关闭防火墙,以及开放安全组
http: ip 地址://15672