mirror of
https://github.com/crawlab-team/crawlab.git
synced 2026-01-21 17:21:09 +01:00
updated docker-compose.yml
This commit is contained in:
12
README-zh.md
12
README-zh.md
@@ -19,7 +19,7 @@
|
|||||||
2. [直接部署](https://tikazyq.github.io/crawlab/Installation/Direct.md)(了解内核)
|
2. [直接部署](https://tikazyq.github.io/crawlab/Installation/Direct.md)(了解内核)
|
||||||
|
|
||||||
### 要求(Docker)
|
### 要求(Docker)
|
||||||
- Docker
|
- Docker 18.03+
|
||||||
- Redis
|
- Redis
|
||||||
- MongoDB 3.6+
|
- MongoDB 3.6+
|
||||||
|
|
||||||
@@ -48,9 +48,17 @@ docker run -d --rm --name crawlab \
|
|||||||
tikazyq/crawlab:0.3.0
|
tikazyq/crawlab:0.3.0
|
||||||
```
|
```
|
||||||
|
|
||||||
|
当然也可以用`docker-compose`来一键启动,甚至不用配置MongoDB和Redis数据库。
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker-compose up
|
||||||
|
```
|
||||||
|
|
||||||
|
Docker部署的详情,请见[相关文档](https://tikazyq.github.io/crawlab/Installation/Docker.md)。
|
||||||
|
|
||||||
### 直接部署
|
### 直接部署
|
||||||
|
|
||||||
请参考文档。
|
请参考[相关文档](https://tikazyq.github.io/crawlab/Installation/Direct.md)。
|
||||||
|
|
||||||
## 截图
|
## 截图
|
||||||
|
|
||||||
|
|||||||
@@ -2,8 +2,9 @@ version: '3.3'
|
|||||||
services:
|
services:
|
||||||
master:
|
master:
|
||||||
image: tikazyq/crawlab:latest
|
image: tikazyq/crawlab:latest
|
||||||
container_name: crawlab
|
container_name: crawlab-master
|
||||||
environment:
|
environment:
|
||||||
|
CRAWLAB_API_ADDRESS: "192.168.99.100:8000"
|
||||||
CRAWLAB_SERVER_MASTER: "Y"
|
CRAWLAB_SERVER_MASTER: "Y"
|
||||||
CRAWLAB_MONGO_HOST: "mongo"
|
CRAWLAB_MONGO_HOST: "mongo"
|
||||||
CRAWLAB_REDIS_ADDRESS: "redis:6379"
|
CRAWLAB_REDIS_ADDRESS: "redis:6379"
|
||||||
@@ -13,6 +14,16 @@ services:
|
|||||||
depends_on:
|
depends_on:
|
||||||
- mongo
|
- mongo
|
||||||
- redis
|
- redis
|
||||||
|
worker:
|
||||||
|
image: tikazyq/crawlab:latest
|
||||||
|
container_name: crawlab-worker
|
||||||
|
environment:
|
||||||
|
CRAWLAB_SERVER_MASTER: "N"
|
||||||
|
CRAWLAB_MONGO_HOST: "mongo"
|
||||||
|
CRAWLAB_REDIS_ADDRESS: "redis:6379"
|
||||||
|
depends_on:
|
||||||
|
- mongo
|
||||||
|
- redis
|
||||||
mongo:
|
mongo:
|
||||||
image: mongo:latest
|
image: mongo:latest
|
||||||
restart: always
|
restart: always
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
docker run -d --rm --name crawlab \
|
docker run -d --restart always --name crawlab \
|
||||||
-e CRAWLAB_REDIS_ADDRESS=192.168.99.1:6379 \
|
-e CRAWLAB_REDIS_ADDRESS=192.168.99.1:6379 \
|
||||||
-e CRAWLAB_MONGO_HOST=192.168.99.1 \
|
-e CRAWLAB_MONGO_HOST=192.168.99.1 \
|
||||||
-e CRAWLAB_SERVER_MASTER=Y \
|
-e CRAWLAB_SERVER_MASTER=Y \
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
docker run --rm --name crawlab \
|
docker run --restart always --name crawlab \
|
||||||
-e CRAWLAB_REDIS_ADDRESS=192.168.99.1:6379 \
|
-e CRAWLAB_REDIS_ADDRESS=192.168.99.1:6379 \
|
||||||
-e CRAWLAB_MONGO_HOST=192.168.99.1 \
|
-e CRAWLAB_MONGO_HOST=192.168.99.1 \
|
||||||
-e CRAWLAB_SERVER_MASTER=N \
|
-e CRAWLAB_SERVER_MASTER=N \
|
||||||
|
|||||||
Reference in New Issue
Block a user