八爪鱼7AI 安装 iStoreOS 教程
目标
在 八爪鱼7AI 这类有 Docker 面板的路由器上,通过 Docker Panel 安装 iStoreOS。
最终效果:
iStoreOS 访问地址:http://192.168.50.33/
debug SSH:ssh -p 2223 debug@BE96AI宿主机IP
debug SSH 密码:debug
前提
示例环境如下:
局域网网段:192.168.50.0/24
网关:192.168.50.1
给 iStoreOS 分配的固定 IP:192.168.50.33
BE96 主网卡:eth0
如果你的局域网不是 192.168.50.0/24,需要把下面 compose 里的 IP、网关改成你自己的。
第一步:在 Docker Panel 创建 Compose
在 DPanel 或其他 Docker 面板里,新建 compose,填入:
services:
istoreos-manager:
image: linkease/be96-debug:latest
container_name: istoreos-manager
restart: unless-stopped
privileged: true
network_mode: host
pid: host
ipc: host
uts: host
cgroup: host
environment:
DEBUG_SSH_PORT: "2223"
DEBUG_PASSWORD: "debug"
ISTOREOS_AUTO_START: "1"
ISTOREOS_CONTAINER: "istoreos"
ISTOREOS_IMAGE: "linkease/istore24.10-in-be96:latest"
ISTOREOS_BRIDGE: "br-istoreos"
ISTOREOS_PARENT: "eth0"
ISTOREOS_STATIC: "192.168.50.33/24"
ISTOREOS_GATEWAY: "192.168.50.1"
ISTOREOS_DNS: "223.5.5.5"
volumes:
- /:/host:rw,rslave
- /var/run/docker.sock:/var/run/docker.sock:rw
然后启动这个 compose。
它会自动做这些事情:
1. 启动 debug SSH
2. 准备宿主 bridge:br-istoreos
3. 把宿主 LAN 网卡 eth0 挂到 br-istoreos
4. 创建 iStoreOS 容器
5. 给 iStoreOS 注入 veth 网卡
6. 让 iStoreOS 内部使用 br-lan
7. 给 iStoreOS 配置固定 IP:192.168.50.33
第二步:等待启动
首次启动需要拉取两个镜像:
linkease/be96-debug:latest
linkease/istore24.10-in-be96:latest
如果 Docker Hub 拉取失败,be96-debug 会自动尝试:
registry.linkease.net:5443/linkease/istore24.10-in-be96:latest
docker.1ms.run/linkease/istore24.10-in-be96:latest
等待 1 到 3 分钟。
第三步:访问 iStoreOS
在同一个局域网里的电脑浏览器打开:
http://192.168.50.33/
或者 LuCI 地址:
http://192.168.50.33/cgi-bin/luci/
第四步:可选,进入 debug 容器检查
如果需要排查,可以 SSH 到 BE96AI 宿主机 IP。
例如 BE96AI 宿主机 IP 是 192.168.50.100:
ssh -p 2223 debug@192.168.50.100
密码:
debug
进入后检查 iStoreOS:
docker ps
docker logs istoreos-manager
docker logs istoreos
docker exec istoreos ip -4 addr
docker exec istoreos ip route
docker exec istoreos uci show network
正常应该能看到:
br-lan 上有 192.168.50.33/24
默认网关是 192.168.50.1
开机自动启动
这个 compose 已经设置了:
restart: unless-stopped
所以 BE96AI 重启后:
istoreos-manager 会自动启动
istoreos-manager 会自动检查并启动 istoreos
iStoreOS 会继续使用 192.168.50.33
常见注意事项
如果 BE96AI 的真实网卡不是 eth0,需要把:
ISTOREOS_PARENT: "eth0"
改成真实网卡名,例如:
enP3p49s0
br0
如果你的网关不是 192.168.50.1,需要改:
ISTOREOS_GATEWAY: "192.168.50.1"
如果 192.168.50.33 已被占用,也需要换一个未被占用的 IP。
镜像信息
debug 管理镜像:
linkease/be96-debug:latest
iStoreOS 镜像:
linkease/istore24.10-in-be96:latest