# 2026-06-05 — 1Panel 1panel-network + 容器名互联 ## 摘要 依据 [1Panel #11676](https://github.com/1Panel-dev/1Panel/issues/11676) 与 [appstore mysql/redis](https://github.com/1Panel-dev/appstore):应用商店 MySQL/Redis 在 `1panel-network`,桥接容器应使用**容器名**而非 `host.docker.internal`。Nexus 自动接入该网络并探测 `1Panel-mysql-*` / `1Panel-redis-*` 预填安装向导。 ## 动机 用户步骤 3 报 `(2003) Can't connect to MySQL server on 'host.docker.internal'`:1Panel MySQL 未映射到 docker 网桥可达地址,或仅监听容器网络。 ## 涉及文件 - `docker/docker-compose.1panel.yml` — 接入 `1panel-network` - `deploy/detect-1panel-services.sh` — 探测容器名 - `deploy/nexus-1panel.sh` — compose 叠加与 env 写入 - `server/api/install.py` — 探测顺序与向导预填 - `deploy/README-1panel.md` ## 验证 ```bash bash deploy/detect-1panel-services.sh nx update --no-cache # 安装向导步骤 3 db_host 应为 1Panel-mysql-xxxx ```