使用Alist聚合网盘并通过Aria2加速下载

一、Alist

1.k8s一键安装

https://github.com/truecharts/public/blob/master/charts/stable/alist/README.md

helm upgrade --install -n alist --create-namespace alist oci://tccr.io/truecharts/alist

2.配置域名访问

kubectl apply -f alist.yaml
# https://doc.traefik.io/traefik/reference/routing-configuration/kubernetes/crd/http/ingressroute/ 
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
  name: traefik-host
  namespace: alist
spec:
  entryPoints:
  - web
  routes:
  - match: Host(`alist.k8s.home.love`) 
    kind: Rule
    services:
      - name: alist
        port: 10167

3.进入pod配置登录密码

# 手动设置一个密码,`NEW_PASSWORD`是指你需要设置的密码
./alist admin set admin

4.添加存储

4.1 KodBox

https://alist.nn.ci/zh/guide/drivers/kodbox.html
在这里插入图片描述

4.2 Seafile

https://alist.nn.ci/zh/guide/drivers/Seafile.html

4.3 MinIO

https://alist.nn.ci/zh/guide/drivers/s3.html

4.4 阿里云盘 Open

https://alist.nn.ci/zh/guide/drivers/aliyundrive_open.html

刷新令牌
前往:https://alist.nn.ci/zh/tool/aliyundrive/request

4.5 天翼云盘

https://alist.nn.ci/zh/guide/drivers/189.html

4.6 百度网盘

https://alist.nn.ci/zh/guide/drivers/baidu.html

4.7 夸克网盘 / TV

https://alist.nn.ci/zh/guide/drivers/quark.html
Cookie
前往:https://pan.quark.cn/
按F12打开“调试”,选中“网络”,随意在左侧选择请求,找到携带 Cookie 参数的就可以

4.8 迅雷云盘/X/浏览器

https://alist.nn.ci/zh/guide/drivers/thunder.html
在获取验证码之前填写手机号先不要携带 +86 区号,将报错里面的链接打开,获取验证码
获取验证码后填写需要携带 +86 区号,例如 +8613722223333 这样填写

4.9 一刻相册

https://alist.nn.ci/zh/guide/drivers/baidu.photo.html

4.10 WebDAV

https://alist.nn.ci/zh/guide/webdav.html

5.最后效果

在这里插入图片描述

6.常见问题

  1. alist数据库爆炸增长,需要先备份配置,然后再重装
    https://alist.nn.ci/zh/guide/advanced/backup.html

    方法1-内置
    使用AList后台的内置 备份/恢复选项
    备份:进行AList数据进行备份(不包含索引)
    恢复:恢复之前备份文件
    覆盖:恢复时选择覆盖会将用户信息进行覆盖
    加密:填写加密密码导出时会将信息进行加密,导入时也需要先输入加密密码再点击恢复3.40.0_新增
    在这里插入图片描述

二、Aria2

1.docker-compose一键安装

docker-compose up -d
#https://github.com/P3TERX/Aria2-Pro-Docker/blob/master/docker-compose.yml
version: "3.8"

services:

  Aria2-Pro:
    container_name: aria2-pro
    image: p3terx/aria2-pro
    environment:
      - PUID=65534
      - PGID=65534
      - UMASK_SET=022
      - RPC_SECRET=aria2
      - RPC_PORT=6800
      - LISTEN_PORT=6888
      - DISK_CACHE=64M
      - IPV6_MODE=false
      - UPDATE_TRACKERS=true
      - CUSTOM_TRACKER_URL=
      - TZ=Asia/Shanghai
    volumes:
      - /root/aria2/config:/config
      - /mnt/raid/downloads:/downloads
# If you use host network mode, then no port mapping is required.
# This is the easiest way to use IPv6 networks.
    network_mode: host
#    network_mode: bridge
#    ports:
#      - 6800:6800
#      - 6888:6888
#      - 6888:6888/udp
    restart: unless-stopped
# Since Aria2 will continue to generate logs, limit the log size to 1M to prevent your hard disk from running out of space.
    logging:
      driver: json-file
      options:
        max-size: 1m

# AriaNg is just a static web page, usually you only need to deploy on a single host.
  AriaNg:
    container_name: ariang
    image: p3terx/ariang
    command: --port 6880 --ipv6
    network_mode: host
#    network_mode: bridge
#    ports:
#      - 6880:6880
    restart: unless-stopped
    logging:
      driver: json-file
      options:
        max-size: 1m

2.k8s两键安装

# 前端
helm upgrade --install -n aria2 --create-namespace ariang oci://tccr.io/truecharts/ariang
# 后端
helm upgrade --install -n aria2 --create-namespace aria2 oci://tccr.io/truecharts/aria2 -f values.yaml

values.yaml文件如下:

# https://github.com/truecharts/public/blob/master/charts/stable/aria2/values.yaml
workload:
  main:
    podSpec:
      containers:
        main:
          env:
            RPC_SECRET: "aria2"

3.配置域名访问

kubectl apply -f aria2.yaml
# https://doc.traefik.io/traefik/reference/routing-configuration/kubernetes/crd/http/ingressroute/ 
apiVersion: traefik.io/v1alpha1
kind: IngressRoute
metadata:
  name: traefik-host
  namespace: aria2
spec:
  entryPoints:
  - web
  routes:
  - match: Host(`aria2.k8s.home.love`) 
    kind: Rule
    services:
      - name: aria2
        port: 6800
  - match: Host(`ariang.k8s.home.love`) 
    kind: Rule
    services:
      - name: ariang
        port: 10276

4.最后效果

4.1 配置AriaNg访问Aria2服务

在这里插入图片描述

4.2 配置Alist下载到Aria2路径下

在这里插入图片描述

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

杜莱恩特Durant

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值