代码拉取完成,页面将自动刷新
同步操作将从 ThingsPanel/thingspanel-docker 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
version: "3.9"
services:
frontend: # 前端
image: registry.cn-hangzhou.aliyuncs.com/thingspanel/thingspanel-vue:v1.0.0
ports:
- "8080:8080"
expose:
- 8080
environment:
# - "BACKEND_HOST=172.19.0.2:9999" #后端接口代理地址(暂无法使用)
- "TZ=Asia/Shanghai"
depends_on: # 隐式地创建了一个依赖关系
- backend
networks:
extnetwork:
ipv4_address: 172.19.0.3
volumes:
- nginx:/etc/nginx
restart: unless-stopped
postgres:
image: registry.cn-hangzhou.aliyuncs.com/thingspanel/timescaledb:14
privileged: true
volumes: # 注意!如果在win系统上运行,可能会有权限问题,可更改为卷映射(去掉文件末尾的卷注释,将下方./data/timescaleDB改为卷timescaleDB即可)
- ./data/timescaleDB:/var/lib/postgresql/data
ports: # 如不需要从外部访问可删除端口映射
- "5555:5432"
environment:
- "TZ=Asia/Shanghai"
- "LC_ALL=C.UTF-8"
- "POSTGRES_DB=ThingsPanel"
- "POSTGRES_USER=postgres"
- "POSTGRES_PASSWORD=postgresThingsPanel"
- "POSTGRES_HOST_AUTH_METHOD=trust"
networks:
extnetwork:
ipv4_address: 172.19.0.4
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 30s
timeout: 10s
retries: 3
restart: unless-stopped
gmqtt:
image: registry.cn-hangzhou.aliyuncs.com/thingspanel/thingspanel-gmqtt:v1.0.0
volumes:
- gmqtt:/gmqttd
ports:
- "1883:1883"
environment: # cmd/gmqttd/thingspanel.yml配置文件中的配置都可以通过环境变量传递
- "TZ=Asia/Shanghai"
- "GMQTT_DB_REDIS_CONN=172.19.0.6:6379"
- "GMQTT_DB_REDIS_PASSWORD=redis"
- "GMQTT_DB_PSQL_PSQLADDR=172.19.0.4"
- "GMQTT_DB_PSQL_PSQLPORT=5432"
- "GMQTT_DB_PSQL_PSQLDB=ThingsPanel"
- "GMQTT_DB_PSQL_PSQLUSER=postgres"
- "GMQTT_DB_PSQL_PSQLPASSWORD=postgresThingsPanel"
hostname: gmqtt
networks:
extnetwork:
ipv4_address: 172.19.0.5
restart: unless-stopped
redis:
image: registry.cn-hangzhou.aliyuncs.com/thingspanel/redis:6.2.7
command: redis-server --requirepass redis
volumes:
- ./data/redis/data:/data
- ./data/redis/conf/redis.conf:/usr/local/etc/redis/redis.conf
- ./data/redis/logs:/logs
ports: # 如不需要从外部访问可删除端口映射
- "6379:6379"
environment:
- "TZ=Asia/Shanghai"
networks:
extnetwork:
ipv4_address: 172.19.0.6
restart: unless-stopped
backend:
image: registry.cn-hangzhou.aliyuncs.com/thingspanel/thingspanel-go:v1.0.0
ports: # 如不需要从外部访问可删除端口映射
- "9999:9999"
environment: # configs/conf.yml配置文件中的配置都可以通过环境变量传递
- "TZ=Asia/Shanghai"
- "GOTP_DB_PSQL_HOST=172.19.0.4"
- "GOTP_DB_PSQL_PORT=5432"
- "GOTP_DB_PSQL_USERNAME=postgres"
- "GOTP_DB_PSQL_PASSWORD=postgresThingsPanel"
- "GOTP_DB_PSQL_DBNAME=ThingsPanel"
- "GOTP_DB_PSQL_LOG_LEVEL=3"
- "GOTP_DB_REDIS_ADDR=172.19.0.6:6379"
- "GOTP_DB_REDIS_PASSWORD=redis"
- "GOTP_MQTT_SERVER=gmqtt"
- "GOTP_MQTT_ACCESS_ADDRESS=域名:1883"
- "GOTP_MQTT_BROKER=172.19.0.5:1883"
- "GOTP_LOG_LEVEL=error"
networks:
extnetwork:
ipv4_address: 172.19.0.2
depends_on:
- gmqtt
- postgres
- redis
volumes:
- go:/go/src/app/files
- go:/go/src/app/conf
restart: unless-stopped
ulimits:
nproc: 524288
nofile:
soft: 20000
hard: 40000
volumes:
go:
gmqtt:
nginx:
# timescaleDB:
networks:
extnetwork:
ipam:
config:
- subnet: 172.19.0.0/16
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。