## Emby 数据迁徙
scp -r emby.tgz [email protected]:/mnt/emby.tgz
scp -r movies [email protected]:/mnt/movies
## 新机器上部署 映射Emby 18096 端口,防止被爬
docker run -d --name=emby -e PUID=1000 -e PGID=1000 -p 18096:8096 \
-v /mnt/emby:/config -v /mnt/movies:/data/movies \
--restart unless-stopped emby/embyserver_arm64v8
## 启动 nginx-php-fpm7.4 容器 https 反代 Emby 18096 端口
docker run -d -p 80:80 -p 443:443 --restart=always \
-v /var/www/cert:/etc/nginx/cert \
-v /var/www/html:/var/www/html \
--name nginx-php \
hongwenjun/nginx-php
## EMBY API
https://m.262235.xyz/emby/web/index.html#!/apikeys
4ef33d761<<实际API>>b63391d - m.262235.xyz
# API 操作参数
http://swagger.emby.media/?url=https://m.262235.xyz/emby/openapi&api_key=4ef33d761<<实际API>>b63391d
# emby info
https://m.262235.xyz/emby/System/Info?api_key=4ef33d761<<实际API>>b63391d
# 建立测试用户
curl -X POST "https://m.262235.xyz/emby/Users/New?api_key=4ef33d761<<实际API>>b63391d" \
-H "accept: application/xml" -H "Content-Type: application/json" -d "{\"Name\":\"python\"}"
https://m.262235.xyz/emby/Users/New?api_key=4ef33d761<<实际API>>b63391d
# python 建立用户 有问题 # data 传替数据还是不会写
import requests
url = 'https://m.262235.xyz/emby/Users/New?api_key=4ef33d761<<实际API>>b63391d'
headers = { "User-Agent": "Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.81 Safari/537.36",
'accept': 'application/xml', 'content-type': 'application/json'}
data ='{\"Name\":\"test\"}' # data 传替数据还是不会写
r = requests.post(url, headers=headers, data =data)
r.text
root@localhost:~# curl -X POST "https://m.262235.xyz/emby/Users/New?api_key=4ef33d761<<实际API>>b63391d" \
-H "accept: application/xml" -H "Content-Type: application/json" -d "{\"Name\":\"python\"}"
© 版权声明
文章版权归作者所有,未经允许请勿转载。
THE END
喜欢就支持一下吧
请登录后发表评论
注册