完成效果:

moviepilot

emby

直链播放

1. moviepilot下载目录(可以不用)
   如:/media/docker/moviepilot/downloads
2. moviepilot整理后的媒体库目录,同时也是cd2挂载网盘目录
   如:/media/docker/moviepilot/media
3. 软链接STRM文件夹
   如:/media/docker/moviepilot/strm

创建公共文件夹

mkdir -p /media/docker/moviepilot/{downloads,media,strm}

部署moviepilot

mkdir -p /media/docker/moviepilot/{config,core}
docker run -itd \
    --name moviepilot \
    --hostname moviepilot \
    -p 8098:3000 \
    -v /media/docker/moviepilot/downloads:/downloads \
    -v /media/docker/moviepilot/media:/media \
    -v /media/docker/moviepilot/config:/config \
    -v /media/docker/moviepilot/core:/moviepilot/.cache/ms-playwright \
    -v /var/run/docker.sock:/var/run/docker.sock:ro \
    -e 'NGINX_PORT=3000' \
    -e 'PORT=3001' \
    -e 'PUID=0' \
    -e 'PGID=0' \
    -e 'UMASK=022' \
    -e 'TZ=Asia/Shanghai' \
    -e 'AUTH_SITE=iyuu' \
    -e 'IYUU_SIGN=IYUU9xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' \
    -e 'SUPERUSER=xxxxx' \ #自定义用户名
    -e 'API_TOKEN=moviepilot' \
    --restart always \
    jxxghp/moviepilot:latest

部署Alist

我选择的是带aria2的版本

mkdir -p /media/docker/alist
docker run -d \
--restart=always \
-v /media/docker/alist:/opt/alist/data \
-p 5244:5244 \
-p 6800:6800 \
-e PUID=0 \
-e PGID=0 \
-e UMASK=022 \
--name=alist \
-e TZ=Asia/Shanghai \
xhofe/alist-aria2:latest

部署clouddrive2

mkdir -p /media/docker/clouddrive/Config
docker run -d \
    --name clouddrive \
    --restart unless-stopped \
    --env CLOUDDRIVE_HOME=/Config \
    -v /media/docker/moviepilot/downloads:/CloudNAS:shared \
    -v /media/docker/moviepilot/media:/media:shared \ #有这个就够了
    -v /media/docker/clouddrive/Config:/Config \
    -p 8097:19798 \
    --pid host \
    --privileged \
    --device=/dev/fuse:/dev/fuse \
    cloudnas/clouddrive2

部署auto_symlink

mkdir -p /media/docker/auto_symlink/config
docker run -d \
  --name auto_symlink \
  -e TZ=Asia/Shanghai \
  -v /media/docker/moviepilot/media:/media/docker/moviepilot/media:rslave \#cd2挂载目录
  -v /media/docker/moviepilot/strm:/media/docker/moviepilot/strm \#emby扫描媒体目录
  -v /media/docker/auto_symlink/config:/app/config \
  -p 8095:8095 \
  --user 0:0 \
  --restart unless-stopped \
  shenxianmq/auto_symlink:latest

auto_symlink设置:

部署emby

主用

mkdir -p /media/docker/emby-server/config
docker run -d \
  --name emby-server \
  --restart=always \
  --privileged \
  -p 8096:8096 \
  -v /media/docker/emby-server/config:/config \
  -v /media/docker/moviepilot/media:/media/docker/moviepilot/media \
  -v /media/docker/moviepilot/strm:/strm \ #有这个就够了
amilys/embyserver:beta

备用

点击展开

mkdir -p /media/docker/emby-server01/config
docker run -d \
--name emby-server01 \
--network=bridge \
-p '8092:8096' \
-p '8920:8920' \
-p '1900:1900/udp' \
-p '7359:7359/udp' \
-v /media/docker/emby-server01/config:/config \
-v /media/docker/moviepilot/media:/media/docker/moviepilot/media \
-v /media/docker/moviepilot/strm:/strm \
-e TZ="Asia/Shanghai" \
-e UID=0 \
-e GID=0 \
-e GIDLIST=0 \
--restart always \
lovechen/embyserver:latest

emby设置:

部署nginx

内置默认脚本,不好用,亦或是现在不能用

点击展开

mkdir -p /media/docker/emby-nginx
docker run -d \
  --name emby-nginx \
  -e TZ=Asia/Shanghai \
  -p 8094:80 \
  -v /media/docker/emby-nginx/constant.js:/etc/nginx/conf.d/constant.js \
  --restart unless-stopped \
  registry.cn-shenzhen.aliyuncs.com/hicane/emby-nginx:latest

首先,打包下载bpking1/embyExternalUrl: some emby/jellyfin scripts (github.com),也就是下边emby2Alist文件中的内容。

最新版项目配置内容可能有所更改,如果不成功,可试试这个:https://s.nloln.cn/IAxX

主用

docker run -d \
   --name=emby-nginx \
   -e PUID=0 \
   -e PGID=0 \
   -e TZ=Asia/Shanghai \
   -v /media/docker/emby2Alist/nginx/nginx.conf:/etc/nginx/nginx.conf \
   -v /media/docker/emby2Alist/nginx/conf.d:/etc/nginx/conf.d \
   -v /media/docker/emby2Alist/nginx/embyCache:/var/cache/nginx/emby \
   -v /media/docker/emby2Alist/nginx/log:/var/log/nginx \
   --restart=always  \
   -p 8094:8091 \
   nginx:latest

备用

点击展开

docker run -d \
   --name=emby-nginx01 \
   -e PUID=0 \
   -e PGID=0 \
   -e TZ=Asia/Shanghai \
   -v /media/docker/emby2Alist01/nginx/nginx.conf:/etc/nginx/nginx.conf \
   -v /media/docker/emby2Alist01/nginx/conf.d:/etc/nginx/conf.d \
   -v /media/docker/emby2Alist01/nginx/embyCache:/var/cache/nginx/emby \
   -v /media/docker/emby2Alist01/nginx/log:/var/log/nginx \
   --restart=always  \
   -p 8091:8091 \
   nginx:latest

nginx设置:

修改三个文件就行了

constant.js

constant-mount.js

constant-pro.js

上边待替换前缀就是下图标记的内容

emby

P.S.:

1.我用的PVE下边的LXC容器搭建的,最开始clouddrive2挂载不了,少了fuse,手动安装也没有,因为宿主机没给这个功能,折腾的半天,只需要再LXC容器选项-功能里边启用就可以了。

fuse

2.各个容器有问题的重启顺序:alist-clouddrive2-auto_symlink(moviepilot)-emby-nginx

参考文章:

https://docs.qq.com/doc/DRmNxYVRpeEZwUGdQ
https://onii.cn/nas/59.html
https://herman-3600.xlog.app/emby-zhi-lian-wang-pan-bo-fang-jiao-cheng-md?locale=en
https://blog.asusai.cn/archives/1715865487752#
https://github.com/bpking1/embyExternalUrl

体验地址:

此处内容需要评论回复后(审核通过)方可阅读。

最后修改:2024 年 09 月 23 日
如果觉得我的文章对你有用,请随意赞赏