修改rocketmq/conf中broker.conf,增加
autoCreateTopicEnable=true
brokerIP1 = 127.0.0.1
namesrvAddr = 127.0.0.1:9876
進入rocketmq/bin
start mqnamesrv.cmd
Start-Process -FilePath "mqbroker.cmd" -ArgumentList "-n 127.0.0.1:9876", "autoCreateTopicEnable=true"
rocketmq-console已經變成了rocketmq dashboard,但是application.yml中的data path還是rocketmq console
執行docker的命令
docker run -d --name rocketmq-dashboard -e "JAVA_OPTS=-Drocketmq.namesrv.addr=127.0.0.1:9876" -p 8080:8080 -t apacherocketmq/rocketmq-dashboard:latest
但是不知道為什麼沒法連線到127.0.0.1:9876,所以還是用vscode裝Spring外掛直接啟動專案