anythingllm上传文档报错:Invalid file upload.ENOENT:no such file or directory.open ‘/collector/hotdir/*.*‘
在Linux服务器通过docker部署anythingllm,在windows本地可以用浏览器打开页面,但是在上传知识库文档时报错:Invalid file upload.ENOENT:no such file or directory.open '/collector/hotdir/*.*'
经过各种修改权限分组,都不起作用,最后参考官网解决,原因应该是版本和启动时参数有问题,正确方式整理如下,如果有遇到同样问题的伙伴希望可以帮到:
1、先创建一个目录用于保存anythingllm的持久化文件:
sudo mkdir /app
sudo mkdir /app/anythingllm/
sudo chmod 777 /app/anythingllm/ -R
2、拉取镜像
docker pull mintplexlabs/anythingllm:latest
3、运行Docker
export STORAGE_LOCATION="/app/anythingllm" && \
mkdir -p $STORAGE_LOCATION && \
touch "$STORAGE_LOCATION/.env" && \
sudo chmod 777 /app/anythingllm/.env && \
docker run -itd -p 8892:3001 \
--cap-add SYS_ADMIN \
--add-host=host.docker.internal:host-gateway \
-v ${STORAGE_LOCATION}:/app/server/storage \
-v ${STORAGE_LOCATION}/.env:/app/server/.env \
-e STORAGE_DIR="/app/server/storage" \
--name anythingllm \
mintplexlabs/anythingllm:latest
4、访问
http://143.211.95.256:23796
这样再上传文档就不会报错了,
官方文档连接:anything-llm/docker/HOW_TO_USE_DOCKER.md at master · Mintplex-Labs/anything-llm
更多推荐


所有评论(0)