docker部署kafka集群、nacos集群
作者:互联网
kafka
docker pull wurstmeister/kafka
docker pull wurstmeister/zookeeper
nacos
拉取镜像
docker pull nacos/nacos-server:2.0.1
三个分别启动
docker run -d \
-e PREFER_HOST_MODE=hostname \
-e MODE=cluster \
-e NACOS_SERVER_PORT=8848 \
-e NACOS_SERVERS="192.168.1.116:8848 192.168.0.232:8848 192.168.0.248:8848" \
-e SPRING_DATASOURCE_PLATFORM=mysql \
-e MYSQL_SERVICE_HOST=192.168.0.233 \
-e MYSQL_SERVICE_PORT=3306 \
-e MYSQL_SERVICE_USER=root \
-e MYSQL_SERVICE_PASSWORD=123456 \
-e MYSQL_SERVICE_DB_NAME=nacos_config \
-e NACOS_SERVER_IP=192.168.1.116 \
-p 8848:8848 \
--name my-nacos1 \
nacos/nacos-server:2.0.1
docker run -d \
-e PREFER_HOST_MODE=hostname \
-e MODE=cluster \
-e NACOS_SERVER_PORT=8848 \
-e NACOS_SERVERS="192.168.1.116:8848 192.168.0.232:8848 192.168.0.248:8848" \
-e SPRING_
标签:SERVICE,nacos,192.168,NACOS,8848,集群,docker 来源: https://blog.csdn.net/yujing1314/article/details/122720211