目的
- 这样阿里云盘就可以通过cloudmounter或者rclone加载到本地了
参考
实现
获得refresh_token
先Chrome网页登陆,然后按F12

(2022-03-01) 更好的方式 登陆 https://www.aliyundrive.com/drive/
JSON.parse(localStorage.token).refresh_token

运行docker
aliyun_refresh_token="4e2143xxxxx35cc73a4c7" aliyun_admin_password="xxxxx" aliyun_driver_port=12280 docker run -d --name=webdav-aliyundriver \ --restart=always -p ${aliyun_driver_port}:8080 \ -v /etc/localtime:/etc/localtime \ -v /data/aliyun-driver/:/etc/aliyun-driver/ \ -e TZ="Asia/Shanghai" \ -e ALIYUNDRIVE_REFRESH_TOKEN=${aliyun_refresh_token} \ -e ALIYUNDRIVE_AUTH_PASSWORD=${aliyun_admin_password} \ -e JAVA_OPTS="-Xmx1g" \ zx5253/webdav-aliyundriver # /etc/aliyun-driver/ 或你自己的本地目录 挂载卷自动维护了最新的refreshToken,建议挂载 # ALIYUNDRIVE_AUTH_PASSWORD 是admin账户的密码,建议修改 # JAVA_OPTS 可修改最大内存占用,比如 -e JAVA_OPTS="-Xmx512m" 表示最大内存限制为512m

本地加载webdav – 记得防火墙对于对应的端口要先打开

结果
