From ff0cc208d0ab63467c4911543afc62cdd0d9e9ac Mon Sep 17 00:00:00 2001 From: Boris <564773807@qq.com> Date: Wed, 13 Apr 2022 16:00:02 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=AF=E6=8C=81=E4=BF=AE=E6=94=B9=E5=90=8E?= =?UTF-8?q?=E7=AB=AF=E5=8F=8A=E7=9B=91=E6=8E=A7=E6=95=B0=E6=8D=AE=E5=BA=93?= =?UTF-8?q?=E5=9C=B0=E5=9D=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env | 4 ++++ docker-compose.yaml | 6 +++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.env b/.env index d637557..68bec5b 100644 --- a/.env +++ b/.env @@ -19,6 +19,10 @@ INFLUXDB_PORT_TCP=8086 INFLUXDB_PORT_UDP=8089 GRAFANA_PORT=3001 +# 后端地址及监控数据库地址,若爬虫节点与后端连不上,则将此处的值都改成内网ip即可 +BACKEND_HOST=feapder_backend +INFLUXDB_HOST=feapder_influxdb + # 监控数据库 INFLUXDB 配置 INFLUXDB_DB=feapder INFLUXDB_ADMIN_USER=root diff --git a/docker-compose.yaml b/docker-compose.yaml index 3937001..6d9e582 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -21,7 +21,7 @@ services: ports: - ${BACKEND_PORT}:${BACKEND_PORT} # 后端端口 (自定义端口:8000) environment: - - FEAPDER_BACKEND_URL=http://feapder_backend:${BACKEND_PORT} + - FEAPDER_BACKEND_URL=http://${BACKEND_HOST}:${BACKEND_PORT} - AUTHORIZATION_CODE=${AUTHORIZATION_CODE} # 授权码 - DB_URL=mysql+pymysql://root:root123@mysql:3306/feapder_platform?charset=utf8mb4 # 后端数据库配置 - REDIS_DB_URL=redis://:feapderYYDS@redis:6379/0 # redis数据库连接配置 redis://[[username]:[password]]@[host]:[port]/[db] @@ -34,7 +34,7 @@ services: # git ssh 私有密钥,不填则使用默认的 - GIT_SSH_PRIVATE_KEY=${GIT_SSH_PRIVATE_KEY} # 监控配置 - - INFLUXDB_HOST=feapder_influxdb + - INFLUXDB_HOST=${INFLUXDB_HOST} - INFLUXDB_DB=${INFLUXDB_DB} - INFLUXDB_ADMIN_USER=${INFLUXDB_ADMIN_USER} - INFLUXDB_ADMIN_PASSWORD=${INFLUXDB_ADMIN_PASSWORD} @@ -95,7 +95,7 @@ services: influxdb: restart: always - image: influxdb:1.8.6 + image: registry.cn-hangzhou.aliyuncs.com/feapderd/influxdb:1.8.6 container_name: feapder_influxdb volumes: - ~/data/feapder/influxdb:/var/lib/influxdb