FUSE for AliyunDrive
Project description
aliyundrive-fuse
🚀 Help me to become a full-time open-source developer by sponsoring me on GitHub
阿里云盘 FUSE 磁盘挂载,主要用于配合 Emby 或者 Jellyfin 观看阿里云盘内容,功能特性:
- 目前只读,不支持写入
- 支持 Linux 和 macOS,暂不支持 Windows
aliyundrive-webdav 项目已经实现了通过 WebDAV 访问阿里云盘内容,但由于 Emby 和 Jellyfin 都不支持直接访问 WebDAV 资源, 需要配合 rclone 之类的软件将 WebDAV 挂载为本地磁盘,而本项目则直接通过 FUSE 实现将阿里云盘挂载为本地磁盘,省去使用 rclone 再做一层中转。
安装
- macOS 需要先安装 macfuse
- Linux 需要先安装 fuse
- Debian 系如 Ubuntu:
apt-get install -y fuse3
- RedHat 系如 CentOS:
yum install -y fuse3
- Debian 系如 Ubuntu:
可以从 GitHub Releases 页面下载预先构建的二进制包, 也可以使用 pip 从 PyPI 下载:
pip install aliyundrive-fuse
如果系统支持 Snapcraft 比如 Ubuntu、Debian 等,也可以使用 snap 安装:
sudo snap install aliyundrive-fuse
OpenWrt 路由器
GitHub Releases 中有预编译的 ipk 文件, 目前提供了 aarch64/arm/x86_64/i686 等架构的版本,可以下载后使用 opkg 安装,以 nanopi r4s 为例:
wget https://github.com/messense/aliyundrive-fuse/releases/download/v0.1.11/aliyundrive-fuse_0.1.11-1_aarch64_generic.ipk
wget https://github.com/messense/aliyundrive-fuse/releases/download/v0.1.11/luci-app-aliyundrive-fuse_0.1.11_all.ipk
wget https://github.com/messense/aliyundrive-fuse/releases/download/v0.1.11/luci-i18n-aliyundrive-fuse-zh-cn_0.1.11-1_all.ipk
opkg install aliyundrive-fuse_0.1.11-1_aarch64_generic.ipk
opkg install luci-app-aliyundrive-fuse_0.1.11_all.ipk
opkg install luci-i18n-aliyundrive-fuse-zh-cn_0.1.11-1_all.ipk
其它 CPU 架构的路由器可在 GitHub Releases 页面中查找对应的架构的主程序 ipk 文件下载安装。
Tips: 不清楚 CPU 架构类型可通过运行
opkg print-architecture
命令查询。
命令行用法
USAGE:
aliyundrive-fuse [OPTIONS] --refresh-token <REFRESH_TOKEN> <PATH>
ARGS:
<PATH> Mount point
OPTIONS:
--allow-other Allow other users to access the drive
--domain-id <DOMAIN_ID> Aliyun PDS domain id
-h, --help Print help information
-r, --refresh-token <REFRESH_TOKEN> Aliyun drive refresh token [env: REFRESH_TOKEN=]
-S, --read-buffer-size <READ_BUFFER_SIZE> Read/download buffer size in bytes, defaults to 10MB [default: 10485760]
-V, --version Print version information
-w, --workdir <WORKDIR> Working directory, refresh_token will be stored in there if specified
比如将磁盘挂载到 /mnt/aliyundrive
目录:
mkdir -p /mnt/aliyundrive /var/run/aliyundrive-fuse
aliyundrive-fuse -r your-refresh-token -w /var/run/aliyundrive-fuse /mnt/aliyundrive
Emby/Jellyfin
如果是直接运行在系统上的 Emby/Jellyfin,则可以直接在其控制台添加媒体库的时候选择阿里云盘对应的挂载路径中的文件夹即可;
如果是 Docker 运行的 Emby/Jellyfin,则需要将阿里云盘挂载路径也挂载到 Docker 容器中,假设阿里云盘挂载路径为 /mnt/aliyundrive
,
以 Jellyfin 为例(假设 Jellyfin 工作路径为 /root/jellyfin
)将云盘挂载到容器 /media
路径:
docker run -d --name jellyfin \
-v /root/jellyfin/config:/config \
-v /root/jellyfin/cache:/cache \
-v /mnt/aliyundrive:/media \
-p 8096:8096 \
--device=/dev/dri/renderD128 \
--device /dev/dri/card0:/dev/dri/card0 \
--restart unless-stopped \
jellyfin/jellyfin
License
This work is released under the MIT license. A copy of the license is provided in the LICENSE file.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for aliyundrive_fuse-0.1.11-py3-none-musllinux_1_1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 054e3b13b4b62c42a87ad4e4cfa309a4a5c0cb6dcfc19addb3c1d8056805a648 |
|
MD5 | b39591824f4e881ddf4d8cad079070bc |
|
BLAKE2b-256 | 3ecdc2e23a98834347b673065bdc2f0f6082c812c22ddff18613dfbbd0092403 |
Hashes for aliyundrive_fuse-0.1.11-py3-none-musllinux_1_1_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 34d796456ed42bb9b1f9ecae7dd88afb65f39c079076e02f044f772818f4b023 |
|
MD5 | 85a336f2071ed8e789be28518ab6f074 |
|
BLAKE2b-256 | 28c361a6772bb178635e13e28d91fd4a3623a577172284a5f2ff3467287318dc |
Hashes for aliyundrive_fuse-0.1.11-py3-none-musllinux_1_1_armv7l.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b2492e45832b635d86ff02c9f34d2b8ea67c1244f72eeba54529812c49281753 |
|
MD5 | 32bc18958a628373f4f720e72f228430 |
|
BLAKE2b-256 | 3b21f645a7c26914f36a84de179547721bc52d5814a95f7e112a9e07a23ba30b |
Hashes for aliyundrive_fuse-0.1.11-py3-none-musllinux_1_1_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fbc86aaceab7e8b722b71e813fc711b0e5b8d06c74da2af613340e1f2cd00afc |
|
MD5 | 8be57e783e86358649e87ab2945dceb3 |
|
BLAKE2b-256 | e24ac6ae7be9125d7cb65893815eee1b4cfd517e32030428a5362e94120e8f5f |
Hashes for aliyundrive_fuse-0.1.11-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c748f2767f6842b192bbb9cec54e17ceef3518c0f895039ae481da9e03301c6f |
|
MD5 | 4719475183bc02b798fc196029435154 |
|
BLAKE2b-256 | 6244dc40fefa8ea999e98417e5f947434352f52e6e9c326b888311ad52175d10 |
Hashes for aliyundrive_fuse-0.1.11-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | af68c7a7f0b99dc4dad7b4c03b1ccb5cddd86a5d0a92a34d3c881c8e11cdcd3f |
|
MD5 | a31b90baff9b7af4ae458a5961aa9319 |
|
BLAKE2b-256 | edcb4c0e15a1d7e2bd23f7a34b69c554a96f60c0a081d4c8353b99008361518b |
Hashes for aliyundrive_fuse-0.1.11-py3-none-manylinux_2_5_x86_64.manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6dfcbd071c04dbb6c57241c78717f883f224921232e0f072b84431af79f1ad6c |
|
MD5 | 46c7c2d3d110632920a137743a2f97ff |
|
BLAKE2b-256 | b6389e412be64515b9c014efe253b8fddde62d5eeedca4166e085a0cbb150f63 |
Hashes for aliyundrive_fuse-0.1.11-py3-none-manylinux_2_5_i686.manylinux1_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 730ec2635357151d102b0fdaabd546ef21ec4f268d89a86713f03d8981b8a87b |
|
MD5 | c42f771f53f50ef1fadcb57ae1a0c1b8 |
|
BLAKE2b-256 | 79d3536711f85b80522b68d2a8b2576c0b67e6411b3e8d17dcb24d4ccc47aeb7 |
Hashes for aliyundrive_fuse-0.1.11-py3-none-macosx_10_7_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9969dae74f808480abcb0d17f914acfefa25f3c405f1a26a4c5e0c3a0e61c8b1 |
|
MD5 | d9f6a2ed5869270cb0202f11c998cee5 |
|
BLAKE2b-256 | 5978bda12fcb279933b5bbfe5f90440b081547d91bcefbc149de7737920e21de |