1.错误信息
bThinkPad-E15:~/mine/zk$ docker stack deploy -c zk.yml zk
services.zoo.environment.0 must be a string
2.定位问题
3.修改后的脚本
thinkPad-E15:~/mine/zk$ cat zk.yml
version: '3.1'
services:
zoo:
image: zookeeper:3.7
restart: always
hostname: zoo
ports:
- 2181:2181
environment:
ZOO_MY_ID: 1
ZOO_SERVERS: server.1=zoo:2888:3888;2181
4.正常启动