Nsq 启动!

官方文档 | 通俗易懂入门

start

添加 docker-compose.yaml

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
version: "3"
services:
nsqlookupd: # 守护进程,调度消息工人
image: nsqio/nsq
command: /nsqlookupd
restart: always
ports:
- "4160:4160"
- "4161:4161"
nsqd: # 消息工人,收发消息
image: nsqio/nsq
hostname: nsqd
command: /nsqd --lookupd-tcp-address=nsqlookupd:4160 --broadcast-address=nsqd
depends_on:
- nsqlookupd
ports:
- "4150:4150"
- "4151:4151"
restart: always

nsqadmin: # 后台管理
image: nsqio/nsq
command: /nsqadmin --lookupd-http-address=nsqlookupd:4161
depends_on:
- nsqlookupd
ports:
- "4171:4171"

执行 docker-compose up -d


本博客所有文章除特别声明外,均采用 CC BY-SA 4.0 协议 ,转载请注明出处!