给小米3C刷了coreelec系统之后,一直没有正经使用过,孩子上学,他做作业的时候咱也不敢刷电视或者手机,只能在旁边找本书看着。25年国庆的时候想起来这一茬,打开盒子一试机,结果alist挂载的网盘都失效了,还看到一个关于alist的新闻,说是因为alist被出售,很多网盘也关闭了对它的支持。开源容易变现难,这里也希望开源工作者们的辛劳付出,能够获得更为合理的回报。因为alist的出售,衍生了另一个分支,openlist,这里尝试一下安装,并复习一下docker的相关指令。
获取列表
首先我们先停止alist服务,在此之前,先核对一下要关闭的服务名称;
docker ps核对服务无误之后,我们尝试关闭alist;
docker stop alist删除用remove指令,-v 表示删除容器时同时删除其挂载的数据卷;
docker remove -v alist安装openlist
拉取镜像到本地:
docker pull ghcr.io/openlistteam/openlist-git运行docker容器,因为coreelec占用了8080端口,所以我们直接考虑用5244端口外部访问:
docker run -d --name openlist-container --restart unless-stopped -v /storage/openlist/config:/config -p 5244:5244 ghcr.io/openlistteam/openlist-git运行后按理应该直接可以以 192.168.99.220:5244 这样的ip+端口的形式访问,但博主的小米3c却一直在反复重启docker,看了一下docker日志:
docker logs openlist-container错误提示如下:
Error: Current user does not have write and/or execute permissions for the ./data directory: /opt/openlist/data
Please visit https://doc.oplist.org/guide/installation/docker#for-version-after-v4-1-0 for more information.
错误:当前用户没有 ./data 目录(/opt/openlist/data)的写和/或执行权限。造成这个问题的原因,可能是博主的系统(coreelec)除了 storage 文件夹外,其他的文件夹默认都是只读属性,导致了容器无法去进行操作,这里是将容器需要改动的文件夹做了个重定向,并在 storage 建立了对应文件夹,这样就绕过了这个问题,以下是重定向容器需要操作的文件夹并重新启动容器的指令:
# 停止并删除当前容器
docker stop openlist-container
docker rm openlist-container
# 创建目录
sudo mkdir -p /storage/openlist/{config,data}
# 设置更宽松的权限(777)
sudo chmod -R 777 /storage/openlist
# 重新运行容器,明确指定用户ID
docker run -d \
--name openlist-container \
--restart unless-stopped \
-v /storage/openlist/config:/config \
-v /storage/openlist/data:/opt/openlist/data \
-p 5244:5244 \
--user 1000:1000 \
ghcr.io/openlistteam/openlist-git接下来是openlist的坑,运行成功后,你会发现用admin123(alist的默认密码)是无法登录的,虽然同气连枝,但还是略有不同,docker版本的openlist在成功运行后,会在log日志里给出随机密码,所以我们需要去检索日志:
docker logs openlist-container
//上述指令运行后输出如下
INFO[2025-10-03 02:23:23] reading config file: /opt/openlist/data/config.json
INFO[2025-10-03 02:23:23] config file not exists, creating default config file
INFO[2025-10-03 02:23:23] load config from env with prefix:
INFO[2025-10-03 02:23:23] max buffer limit: 40MB
INFO[2025-10-03 02:23:23] mmap threshold: 4MB
INFO[2025-10-03 02:23:23] init logrus...
Successfully created the admin user and the initial password is: ********

