mirror of
https://gitee.com/ledc/IYUUAutoReseed
synced 2025-08-24 15:04:50 +00:00
Compare commits
65 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
c2e5b4d00b | ||
|
207320ede7 | ||
|
6e1653fc1e | ||
|
32ec80d552 | ||
|
2b989f9e0e | ||
|
ff16781da9 | ||
|
6a01b492ce | ||
|
de41bc0131 | ||
|
6b83e9081b | ||
|
87f06ec5c4 | ||
|
8a051d4d1f | ||
|
0e32e625a4 | ||
|
a09dacbd20 | ||
|
e3a9c32174 | ||
|
c8a94bfcff | ||
|
fd87d07539 | ||
|
df7100e4e9 | ||
|
44f5b82650 | ||
|
f5a33843e6 | ||
|
7428144aa8 | ||
|
cc325dc128 | ||
|
3d675ed4bd | ||
|
eabb51c54a | ||
|
1e1a7bfc59 | ||
|
005788827d | ||
|
ffb600c334 | ||
|
290bfbe5c9 | ||
|
6ecf4f1d54 | ||
|
c809e8d052 | ||
|
8d7dffbf3d | ||
|
cc50804b40 | ||
|
4444aec4fb | ||
|
68e128e5cd | ||
|
ec7032698d | ||
|
5308c691b6 | ||
|
c7f4859cb7 | ||
|
dc651174b8 | ||
|
a95e579cf6 | ||
|
4811937f42 | ||
|
f9674c1898 | ||
|
2fdacc6936 | ||
|
a2034f2840 | ||
|
4894464fdd | ||
|
c90acbec6c | ||
|
c4a8cef4ce | ||
|
cc7eb9b06a | ||
|
ea3f3deaa8 | ||
|
44c0bcdeb4 | ||
|
d015cd56a6 | ||
|
4cf1222b37 | ||
|
b5f4537df7 | ||
|
1e428a04b7 | ||
|
4c7fd2cf3d | ||
|
43b8bc050b | ||
|
1c1ecd33b8 | ||
|
e201505dca | ||
|
e02d32b129 | ||
|
01a9b71e9f | ||
|
f89b5f7325 | ||
|
5880f563e8 | ||
|
61eb8f69c9 | ||
|
b4ca455a75 | ||
|
02205e6ce3 | ||
|
818794a19b | ||
|
88bc79ff58 |
@@ -1,2 +0,0 @@
|
||||
@echo off
|
||||
composer create-project ledccn/iyuuautoreseed:dev-master
|
@@ -1,5 +0,0 @@
|
||||
@echo off
|
||||
chcp 65001
|
||||
git clone https://gitee.com/ledc/IYUUAutoReseed.git
|
||||
cd IYUUAutoReseed
|
||||
php ./iyuu.php
|
@@ -2,4 +2,6 @@
|
||||
chcp 65001
|
||||
git fetch --all
|
||||
git reset --hard origin/master
|
||||
git pull
|
||||
#git pull
|
||||
php %cd%\iyuu.php
|
||||
pause
|
@@ -1,4 +1,4 @@
|
||||
@echo off
|
||||
chcp 65001
|
||||
%cd%\php\php %cd%\iyuu.php
|
||||
php %cd%\iyuu.php
|
||||
pause
|
@@ -1,7 +0,0 @@
|
||||
@echo off
|
||||
chcp 65001
|
||||
git fetch --all
|
||||
git reset --hard origin/master
|
||||
git pull
|
||||
%cd%\php\php.exe %cd%\iyuu.php
|
||||
pause
|
@@ -1,4 +0,0 @@
|
||||
@echo off
|
||||
chcp 65001
|
||||
D:\IYUUAutoReseed\php\php.exe D:\IYUUAutoReseed\iyuu.php
|
||||
exit
|
@@ -13,19 +13,19 @@ use IYUU\Library\Table;
|
||||
class AutoReseed
|
||||
{
|
||||
// 版本号
|
||||
const VER = '1.6.3';
|
||||
const VER = '1.9.4';
|
||||
// RPC连接
|
||||
private static $links = array();
|
||||
private static $links = [];
|
||||
// 客户端配置
|
||||
private static $clients = array();
|
||||
private static $clients = [];
|
||||
// 站点列表
|
||||
private static $sites = array();
|
||||
// 不辅种的站点 'ourbits','hdchina'
|
||||
private static $noReseed = array();
|
||||
private static $sites = [];
|
||||
// 不辅种的站点 'pt','hdchina'
|
||||
private static $noReseed = [];
|
||||
// 不转移的站点 'hdarea','hdbd'
|
||||
private static $noMove = array('');
|
||||
private static $noMove = [];
|
||||
// cookie检查
|
||||
private static $cookieCheck = array('hdchina','hdcity');
|
||||
private static $cookieCheck = ['hdchina','hdcity'];
|
||||
// 缓存路径
|
||||
public static $cacheDir = TORRENT_PATH.'cache'.DS;
|
||||
public static $cacheHash = TORRENT_PATH.'cachehash'.DS;
|
||||
@@ -56,6 +56,8 @@ class AutoReseed
|
||||
'reseedRepeat' => 0, // 重复:客户端已做种
|
||||
'reseedSkip' => 0, // 跳过:因未设置passkey,而跳过
|
||||
'reseedPass' => 0, // 忽略:因上次成功添加、存在缓存,而跳过
|
||||
'MoveSuccess' => 0, // 移动成功
|
||||
'MoveError' => 0, // 移动失败
|
||||
);
|
||||
// 错误通知消息体
|
||||
private static $errNotify = array(
|
||||
@@ -69,22 +71,20 @@ class AutoReseed
|
||||
public static function init()
|
||||
{
|
||||
global $configALL;
|
||||
echo "正在初始化运行参数,版本号:".self::VER.PHP_EOL;
|
||||
sleep(mt_rand(1, 3));
|
||||
self::backup('config', $configALL);
|
||||
self::$curl = new Curl();
|
||||
self::$curl->setOpt(CURLOPT_SSL_VERIFYPEER, false);
|
||||
self::$curl->setOpt(CURLOPT_SSL_VERIFYHOST, false);
|
||||
self::$curl->setOpt(CURLOPT_SSL_VERIFYHOST, 2);
|
||||
|
||||
// 合作站点自动注册鉴权
|
||||
$is_login = Oauth::login(self::$apiUrl . self::$endpoints['login']);
|
||||
if(!$is_login){
|
||||
echo '合作站点鉴权配置,请查阅:https://www.iyuu.cn/archives/337/';
|
||||
}
|
||||
// 合作站点自动鉴权绑定
|
||||
Oauth::login(self::$apiUrl . self::$endpoints['login']);
|
||||
|
||||
// 显示支持站点列表
|
||||
self::ShowTableSites();
|
||||
|
||||
self::$clients = isset($configALL['default']['clients']) && $configALL['default']['clients'] ? $configALL['default']['clients'] : array();
|
||||
echo "程序正在初始化运行参数... ".PHP_EOL;
|
||||
|
||||
// 递归删除上次历史记录
|
||||
IFile::rmdir(self::$cacheDir, true);
|
||||
// 建立目录
|
||||
@@ -99,15 +99,18 @@ class AutoReseed
|
||||
*/
|
||||
private static function ShowTableSites()
|
||||
{
|
||||
$list[] = 'gitee 源码仓库:https://gitee.com/ledc/IYUUAutoReseed';
|
||||
$list[] = 'github源码仓库:https://github.com/ledccn/IYUUAutoReseed';
|
||||
$list[] = '教程:https://gitee.com/ledc/IYUUAutoReseed/tree/master/wiki';
|
||||
$list[] = "QQ群:859882209 【IYUU自动辅种交流】".PHP_EOL;
|
||||
foreach ($list as $key => $value) {
|
||||
$list = [
|
||||
'gitee源码仓库:https://gitee.com/ledc/IYUUAutoReseed',
|
||||
'github源码仓库:https://github.com/ledccn/IYUUAutoReseed',
|
||||
'教程:https://gitee.com/ledc/IYUUAutoReseed/tree/master/wiki',
|
||||
'问答社区:http://wenda.iyuu.cn',
|
||||
'【IYUU自动辅种交流】QQ群:859882209、931954050'.PHP_EOL,
|
||||
'正在连接IYUUAutoReseed服务器,查询支持列表……'.PHP_EOL
|
||||
];
|
||||
foreach ($list as $value) {
|
||||
echo $value.PHP_EOL;
|
||||
}
|
||||
echo "正在连接IYUUAutoReseed服务器,查询支持列表…… ".PHP_EOL;
|
||||
$res = self::$curl->get(self::$apiUrl.self::$endpoints['sites'].'?sign='.Oauth::getSign());
|
||||
$res = self::$curl->get(self::$apiUrl.self::$endpoints['sites'].'?sign='.Oauth::getSign().'&version='.self::VER);
|
||||
$rs = json_decode($res->response, true);
|
||||
$sites = isset($rs['data']['sites']) && $rs['data']['sites'] ? $rs['data']['sites'] : false;
|
||||
// 数据写入本地
|
||||
@@ -122,10 +125,10 @@ class AutoReseed
|
||||
@fclose($file_pointer);
|
||||
} else {
|
||||
if (isset($rs['msg']) && $rs['msg']) {
|
||||
die($rs['msg']);
|
||||
die($rs['msg'].PHP_EOL);
|
||||
}
|
||||
if (isset($rs['errmsg']) && $rs['errmsg']) {
|
||||
die($rs['errmsg']);
|
||||
die($rs['errmsg'].PHP_EOL);
|
||||
}
|
||||
die('远端服务器无响应,请稍后再试!!!');
|
||||
}
|
||||
@@ -142,7 +145,7 @@ class AutoReseed
|
||||
$data[$k][] = $j.". ".$v['site'];
|
||||
}
|
||||
echo "IYUUAutoReseed自动辅种脚本,目前支持以下站点:".PHP_EOL;
|
||||
//输出表格
|
||||
// 输出支持站点表格
|
||||
$table = new Table();
|
||||
$table->setRows($data);
|
||||
echo($table->render());
|
||||
@@ -150,7 +153,7 @@ class AutoReseed
|
||||
/**
|
||||
* 连接远端RPC下载器
|
||||
*/
|
||||
public static function links()
|
||||
private static function links()
|
||||
{
|
||||
foreach (self::$clients as $k => $v) {
|
||||
// 跳过未配置的客户端
|
||||
@@ -165,14 +168,15 @@ class AutoReseed
|
||||
self::$links[$k]['rpc'] = $client;
|
||||
self::$links[$k]['type'] = $v['type'];
|
||||
self::$links[$k]['BT_backup'] = isset($v['BT_backup']) && $v['BT_backup'] ? $v['BT_backup'] : '';
|
||||
self::$links[$k]['root_folder'] = isset($v['root_folder']) ? $v['root_folder'] : 1;
|
||||
$result = $client->status();
|
||||
print $v['type'].':'.$v['host']." Rpc连接 [{$result}] \n";
|
||||
// 检查转移做种
|
||||
if (isset($v['move']) && $v['move'] && is_null(self::$move)) {
|
||||
// 检查转移做种 (self::$move为空,移动配置为真)
|
||||
if (is_null(self::$move) && isset($v['move']) && $v['move']) {
|
||||
self::$move = array($k,$v['move']);
|
||||
}
|
||||
} catch (\Exception $e) {
|
||||
die('[Links ERROR] ' . $e->getMessage() . PHP_EOL);
|
||||
die('[连接错误] ' . $e->getMessage() . PHP_EOL);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -222,11 +226,15 @@ class AutoReseed
|
||||
break;
|
||||
case 'qBittorrent':
|
||||
$extra_options['autoTMM'] = 'false'; //关闭自动种子管理
|
||||
#$extra_options['skip_checking'] = 'true'; //跳校验
|
||||
// 添加任务校验后是否暂停
|
||||
if (isset($extra_options['paused'])) {
|
||||
$extra_options['paused'] = $extra_options['paused'] ? 'true' : 'false';
|
||||
} else {
|
||||
$extra_options['paused'] = 'true';
|
||||
}
|
||||
// 是否创建根目录
|
||||
$extra_options['root_folder'] = self::$links[$rpcKey]['root_folder'] ? 'true' : 'false';
|
||||
if ($is_url) {
|
||||
$result = self::$links[$rpcKey]['rpc']->add($torrent, $save_path, $extra_options); // 种子URL添加下载任务
|
||||
} else {
|
||||
@@ -243,16 +251,16 @@ class AutoReseed
|
||||
}
|
||||
break;
|
||||
default:
|
||||
echo '[add ERROR] '.$type. PHP_EOL. PHP_EOL;
|
||||
echo '[下载器类型错误] '.$type. PHP_EOL. PHP_EOL;
|
||||
break;
|
||||
}
|
||||
} catch (\Exception $e) {
|
||||
echo '[add ERROR] ' . $e->getMessage() . PHP_EOL;
|
||||
echo '[添加下载任务出错] ' . $e->getMessage() . PHP_EOL;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
/**
|
||||
* 转移、辅种总入口
|
||||
* 辅种或转移,总入口
|
||||
*/
|
||||
public static function call()
|
||||
{
|
||||
@@ -265,13 +273,13 @@ class AutoReseed
|
||||
/**
|
||||
* IYUUAutoReseed辅种
|
||||
*/
|
||||
public static function reseed()
|
||||
private static function reseed()
|
||||
{
|
||||
global $configALL;
|
||||
// 支持站点数量
|
||||
self::$wechatMsg['sitesCount'] = count(self::$sites);
|
||||
$sites = self::$sites;
|
||||
// 按客户端循环辅种 开始
|
||||
// 遍历客户端 开始
|
||||
foreach (self::$links as $k => $v) {
|
||||
if (empty($v)) {
|
||||
echo "clients_".$k." 用户名或密码未配置,已跳过".PHP_EOL.PHP_EOL;
|
||||
@@ -319,18 +327,17 @@ class AutoReseed
|
||||
// 判断返回值
|
||||
if (empty($res['msg'])) {
|
||||
echo "clients_".$k." 辅种数据下载成功!!!".PHP_EOL.PHP_EOL;
|
||||
echo '【提醒】未配置passkey的站点都会跳过!'.PHP_EOL.PHP_EOL;
|
||||
} else {
|
||||
$errmsg = isset($res['msg']) && $res['msg'] ? $res['msg'] : '远端服务器无响应,请稍后重试!';
|
||||
echo '-----辅种失败,原因:' .$errmsg.PHP_EOL.PHP_EOL;
|
||||
continue;
|
||||
}
|
||||
// 当前客户端可辅种数据
|
||||
// 遍历当前客户端可辅种数据
|
||||
foreach ($reseed as $info_hash => $vv) {
|
||||
// 当前种子哈希对应的目录
|
||||
$downloadDir = $infohash_Dir[$info_hash];
|
||||
foreach ($vv['torrent'] as $id => $value) {
|
||||
$_url = $url = '';
|
||||
$download_page = $details_url = '';
|
||||
// 匹配的辅种数据累加
|
||||
self::$wechatMsg['reseedCount']++;
|
||||
// 站点id
|
||||
@@ -348,16 +355,20 @@ class AutoReseed
|
||||
self::setNotify($siteName, $sid, $torrent_id);
|
||||
// 页面规则
|
||||
$download_page = str_replace('{}', $torrent_id, $sites[$sid]['download_page']);
|
||||
$_url = 'https://' .$sites[$sid]['base_url']. '/' .$download_page;
|
||||
echo "clients_".$k."正在辅种... {$siteName}".PHP_EOL;
|
||||
// 协议
|
||||
$protocol = $sites[$sid]['is_https'] == 0 ? 'http://' : 'https://';
|
||||
$_url = $protocol . $sites[$sid]['base_url']. '/' .$download_page;
|
||||
|
||||
/**
|
||||
* 前置检测
|
||||
*/
|
||||
// passkey检测
|
||||
if (empty($configALL[$siteName]['passkey'])) {
|
||||
echo '-------因当前' .$siteName. "站点未设置passkey,已跳过!!".PHP_EOL.PHP_EOL;
|
||||
// 配置与passkey检测
|
||||
if (empty($configALL[$siteName]) || empty($configALL[$siteName]['passkey'])) {
|
||||
//echo '-------因当前' .$siteName. "站点未设置passkey,已跳过!!".PHP_EOL.PHP_EOL;
|
||||
self::$wechatMsg['reseedSkip']++;
|
||||
continue;
|
||||
} else {
|
||||
echo "clients_".$k."正在辅种... {$siteName}".PHP_EOL;
|
||||
}
|
||||
// cookie检测
|
||||
if (in_array($siteName, self::$cookieCheck) && empty($configALL[$siteName]['cookie'])) {
|
||||
@@ -397,22 +408,51 @@ class AutoReseed
|
||||
wlog('clients_'.$k.PHP_EOL.$downloadDir.PHP_EOL.$_url.PHP_EOL.PHP_EOL, $siteName);
|
||||
continue;
|
||||
}
|
||||
// 操作站点流控的配置
|
||||
if (isset($configALL[$siteName]['limitRule']) && $configALL[$siteName]['limitRule']) {
|
||||
$limitRule = $configALL[$siteName]['limitRule'];
|
||||
if (isset($limitRule['count']) && isset($limitRule['sleep'])) {
|
||||
if ($limitRule['count'] <= 0) {
|
||||
echo '-------当前站点辅种数量已满足规则,保障账号安全已跳过:'.$_url.PHP_EOL.PHP_EOL;
|
||||
self::$wechatMsg['reseedPass']++;
|
||||
continue;
|
||||
} else {
|
||||
// 异步间隔流控算法:各站独立、执行时间最优
|
||||
$lastTime = isset($limitRule['time']) ? $limitRule['time'] : 0; // 最近一次辅种成功的时间
|
||||
if ($lastTime) {
|
||||
$interval = time() - $lastTime; // 间隔时间
|
||||
if ($interval < $limitRule['sleep']) {
|
||||
$t = $limitRule['sleep'] - $interval + mt_rand(1, 5);
|
||||
do {
|
||||
echo microtime(true)." 为账号安全,辅种进程休眠 {$t} 秒后继续...".PHP_EOL;
|
||||
sleep(1);
|
||||
} while (--$t > 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
echo '-------当前站点流控规则错误,缺少count或sleep参数!请重新配置!'.$_url.PHP_EOL.PHP_EOL;
|
||||
self::$wechatMsg['reseedPass']++;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 种子URL组合方式区分
|
||||
*/
|
||||
$url = self::getTorrentUrl($siteName, $_url);
|
||||
$reseedPass = false;
|
||||
// 特殊站点:推送给下载器种子元数据
|
||||
$reseedPass = false; // 标志:跳过辅种
|
||||
// 特殊站点:种子元数据推送给下载器
|
||||
switch ($siteName) {
|
||||
case 'hdchina':
|
||||
$cookie = isset($configALL[$siteName]['cookie']) ? $configALL[$siteName]['cookie'] : '';
|
||||
$cookie = $configALL[$siteName]['cookie'];
|
||||
$userAgent = $configALL['default']['userAgent'];
|
||||
// 拼接URL
|
||||
$details_page = str_replace('{}', $value['torrent_id'], 'details.php?id={}&hit=1');
|
||||
$details_url = 'https://' .$sites[$sid]['base_url']. '/' .$details_page;
|
||||
$details_url = $protocol .$sites[$sid]['base_url']. '/' .$details_page;
|
||||
print "种子详情页:".$details_url.PHP_EOL;
|
||||
$details_html = download($details_url, $cookie, $userAgent);
|
||||
if (empty($details_html)) {
|
||||
ff($siteName. '站点,cookie已过期,请更新后重新辅种!');
|
||||
echo 'cookie已过期,请更新后重新辅种!已加入排除列表'.PHP_EOL;
|
||||
$t = 30;
|
||||
do {
|
||||
@@ -420,30 +460,33 @@ class AutoReseed
|
||||
sleep(1);
|
||||
} while (--$t > 0);
|
||||
$configALL[$siteName]['cookie'] = '';
|
||||
// 标志:跳过辅种
|
||||
$reseedPass = true;
|
||||
break;
|
||||
}
|
||||
if (strpos($details_html, '没有该ID的种子') != false) {
|
||||
echo '种子已被删除!'.PHP_EOL;
|
||||
self::sendNotify('404');
|
||||
// 标志:跳过辅种
|
||||
$reseedPass = true;
|
||||
break;
|
||||
}
|
||||
// 提取种子下载地址
|
||||
$download_page = str_replace('{}', '', $sites[$sid]['download_page']);
|
||||
$offset = strpos($details_html, $download_page);
|
||||
$urlTemp = substr($details_html, $offset, 50);
|
||||
// 种子地址
|
||||
$_url = substr($urlTemp, 0, strpos($urlTemp, '">'));
|
||||
if (empty($_url)) {
|
||||
echo '未知错误,未提取到种子URL,请联系脚本作者!'.PHP_EOL;
|
||||
// 标志:跳过辅种
|
||||
$offset = strpos($details_html, str_replace('{hash}', '', $sites[$sid]['download_page']));
|
||||
if ($offset === false) {
|
||||
ff($siteName. '站点,cookie已过期,请更新后重新辅种!');
|
||||
echo 'cookie已过期,请更新后重新辅种!'.PHP_EOL;
|
||||
$configALL[$siteName]['cookie'] = '';
|
||||
$reseedPass = true;
|
||||
break;
|
||||
}
|
||||
$_url = 'https://' .$sites[$sid]['base_url']. '/' . $_url;
|
||||
$urlTemp = substr($details_html, $offset, 50);
|
||||
// 种子地址
|
||||
$download_page = substr($urlTemp, 0, strpos($urlTemp, '">'));
|
||||
if (empty($download_page)) {
|
||||
echo '未知错误,未提取到种子URL,请联系脚本作者!'.PHP_EOL;
|
||||
$reseedPass = true;
|
||||
break;
|
||||
}
|
||||
$_url = $protocol . $sites[$sid]['base_url']. '/' . $download_page;
|
||||
print "种子下载页:".$_url.PHP_EOL;
|
||||
$url = download($_url, $cookie, $userAgent);
|
||||
#p($url);
|
||||
@@ -457,7 +500,6 @@ class AutoReseed
|
||||
} while (--$t > 0);
|
||||
ff($siteName. '站点,辅种时触发第一次下载提示!');
|
||||
self::$noReseed[] = 'hdchina';
|
||||
// 标志:跳过辅种
|
||||
$reseedPass = true;
|
||||
}
|
||||
if (strpos($url, '系统检测到过多的种子下载请求') != false) {
|
||||
@@ -465,12 +507,11 @@ class AutoReseed
|
||||
ff($siteName. '站点,辅种时触发人机验证!');
|
||||
$configALL[$siteName]['limit'] = 1;
|
||||
self::$noReseed[] = 'hdchina';
|
||||
// 标志:跳过辅种
|
||||
$reseedPass = true;
|
||||
}
|
||||
break;
|
||||
case 'hdcity':
|
||||
$cookie = isset($configALL[$siteName]['cookie']) ? $configALL[$siteName]['cookie'] : '';
|
||||
$cookie = $configALL[$siteName]['cookie'];
|
||||
$userAgent = $configALL['default']['userAgent'];
|
||||
print "种子:".$_url.PHP_EOL;
|
||||
if (isset($configALL[$siteName]['cuhash'])) {
|
||||
@@ -478,14 +519,21 @@ class AutoReseed
|
||||
# code...
|
||||
} else {
|
||||
// 获取cuhash
|
||||
$html = download('https://' .$sites[$sid]['base_url']. '/pt', $cookie, $userAgent);
|
||||
$html = download($protocol .$sites[$sid]['base_url']. '/pt', $cookie, $userAgent);
|
||||
// 提取种子下载地址
|
||||
$offset = strpos($html, 'cuhash=');
|
||||
if ($offset === false) {
|
||||
ff($siteName. '站点,cookie已过期,请更新后重新辅种!');
|
||||
echo 'cookie已过期,请更新后重新辅种!'.PHP_EOL;
|
||||
$configALL[$siteName]['cookie'] = '';
|
||||
$reseedPass = true;
|
||||
break;
|
||||
}
|
||||
$len = strlen('cuhash=');
|
||||
$cuhashTemp = substr($html, $offset+$len, 40);
|
||||
$configALL[$siteName]['cuhash'] = substr($cuhashTemp, 0, strpos($cuhashTemp, '"'));
|
||||
}
|
||||
$url = $_url."&cuhash=". $configALL[$siteName]['cuhash'];
|
||||
$url = str_replace('{cuhash}', $configALL[$siteName]['cuhash'], $_url);
|
||||
// 城市下载种子时会302转向
|
||||
$url = download($url, $cookie, $userAgent);
|
||||
if (strpos($url, 'Non-exist torrent id!') != false) {
|
||||
@@ -524,6 +572,14 @@ class AutoReseed
|
||||
$log = 'clients_'.$k.PHP_EOL.$downloadDir.PHP_EOL.$url.PHP_EOL.PHP_EOL;
|
||||
if ($ret) {
|
||||
// 成功的种子
|
||||
// 操作流控参数
|
||||
if (isset($configALL[$siteName]['limitRule']) && $configALL[$siteName]['limitRule']) {
|
||||
$limitRule = $configALL[$siteName]['limitRule'];
|
||||
if ($limitRule['count']) {
|
||||
$configALL[$siteName]['limitRule']['count']--;
|
||||
$configALL[$siteName]['limitRule']['time'] = time();
|
||||
}
|
||||
}
|
||||
wlog($log, $value['info_hash'], self::$cacheHash);
|
||||
wlog($log, 'reseedSuccess');
|
||||
// 成功累加
|
||||
@@ -544,16 +600,18 @@ class AutoReseed
|
||||
/**
|
||||
* IYUUAutoReseed做种客户端转移
|
||||
*/
|
||||
public static function move()
|
||||
private static function move()
|
||||
{
|
||||
global $configALL;
|
||||
//遍历客户端
|
||||
foreach (self::$links as $k => $v) {
|
||||
if (self::$move[0] == $k) {
|
||||
echo "clients_".$k."是目标转移客户端,避免冲突,已跳过!".PHP_EOL.PHP_EOL;
|
||||
continue;
|
||||
}
|
||||
echo "正在从下载器 clients_".$k." 获取种子哈希……".PHP_EOL;
|
||||
$hashArray = self::$links[$k]['rpc']->getList(self::$move);
|
||||
$move = []; // 客户端做种列表 传址
|
||||
$hashArray = self::$links[$k]['rpc']->getList($move);
|
||||
if (empty($hashArray)) {
|
||||
// 失败
|
||||
continue;
|
||||
@@ -568,8 +626,12 @@ class AutoReseed
|
||||
echo "clients_".$k." 全部转移成功,本次无需转移!".PHP_EOL.PHP_EOL;
|
||||
continue;
|
||||
}
|
||||
// 循环转移做种客户端
|
||||
//遍历当前客户端种子
|
||||
foreach ($infohash_Dir as $info_hash => $downloadDir) {
|
||||
// 调用路径过滤
|
||||
if (self::pathFilter($downloadDir)) {
|
||||
continue;
|
||||
}
|
||||
// 做种实际路径与相对路径之间互转
|
||||
echo '转换前:'.$downloadDir.PHP_EOL;
|
||||
$downloadDir = self::pathReplace($downloadDir);
|
||||
@@ -614,11 +676,12 @@ class AutoReseed
|
||||
$torrent = file_get_contents($torrentPath);
|
||||
// 正式开始转移
|
||||
echo "种子已推送给下载器,正在转移做种...".PHP_EOL;
|
||||
$ret = false;
|
||||
|
||||
// 目标下载器类型
|
||||
$rpcKey = self::$move[0];
|
||||
$type = self::$links[$rpcKey]['type'];
|
||||
$extra_options = array();
|
||||
// 转移后,是否开始?
|
||||
$extra_options['paused'] = isset($configALL['default']['move']['paused']) && $configALL['default']['move']['paused'] ? true : false;
|
||||
if ($type == 'qBittorrent') {
|
||||
if (isset($configALL['default']['move']['skip_check']) && $configALL['default']['move']['skip_check'] === 1) {
|
||||
@@ -626,6 +689,7 @@ class AutoReseed
|
||||
}
|
||||
} else {
|
||||
}
|
||||
|
||||
// 添加转移任务:成功返回:true
|
||||
$ret = self::add(self::$move[0], $torrent, $downloadDir, $extra_options);
|
||||
/**
|
||||
@@ -640,9 +704,11 @@ class AutoReseed
|
||||
// 转移成功的种子,以infohash为文件名,写入缓存
|
||||
wlog($log, $info_hash, self::$cacheMove);
|
||||
wlog($log, 'MoveSuccess'.$k);
|
||||
self::$wechatMsg['MoveSuccess']++;
|
||||
} else {
|
||||
// 失败的种子
|
||||
wlog($log, 'MoveError'.$k);
|
||||
self::$wechatMsg['MoveError']++;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -650,7 +716,7 @@ class AutoReseed
|
||||
/**
|
||||
* 过滤已转移的种子hash
|
||||
*/
|
||||
public static function hashFilter(&$infohash_Dir = array())
|
||||
private static function hashFilter(&$infohash_Dir = array())
|
||||
{
|
||||
foreach ($infohash_Dir as $info_hash => $dir) {
|
||||
if (is_file(self::$cacheMove . $info_hash.'.txt')) {
|
||||
@@ -663,7 +729,7 @@ class AutoReseed
|
||||
/**
|
||||
* 实际路径与相对路径之间互相转换
|
||||
*/
|
||||
public static function pathReplace($path = '')
|
||||
private static function pathReplace($path = '')
|
||||
{
|
||||
global $configALL;
|
||||
$type = $configALL['default']['move']['type'];
|
||||
@@ -679,70 +745,141 @@ class AutoReseed
|
||||
break;
|
||||
case 2: // 加
|
||||
foreach ($pathArray as $key => $val) {
|
||||
if (strpos($path, $key)===0) {
|
||||
if (strpos($path, $key)===0) { // 没用$path == $key判断,是为了提高兼容性
|
||||
return $val . $path;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 3: // 替换
|
||||
foreach ($pathArray as $key => $val) {
|
||||
if (strpos($path, $key)===0) {
|
||||
if (strpos($path, $key)===0) { // 没用$path == $key判断,是为了提高兼容性
|
||||
return $val . substr($path, strlen($key));
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
default: // 不变
|
||||
return $path;
|
||||
break;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
/**
|
||||
* 获取站点种子的URL
|
||||
* 处理转移种子时所设置的过滤器、选择器
|
||||
* @return bool true 过滤 | false 不过滤
|
||||
*/
|
||||
public static function getTorrentUrl($site = '', $_url = '')
|
||||
private static function pathFilter(&$path = '')
|
||||
{
|
||||
global $configALL;
|
||||
switch ($site) {
|
||||
case 'ttg':
|
||||
$url = $_url."/". $configALL[$site]['passkey'];
|
||||
break;
|
||||
case 'm-team':
|
||||
case 'moecat':
|
||||
$ip_type = '';
|
||||
if (isset($configALL[$site]['ip_type'])) {
|
||||
$ip_type = $configALL[$site]['ip_type'] == 'ipv6' ? '&ipv6=1' : '';
|
||||
$path = rtrim($path, DIRECTORY_SEPARATOR); // 提高Windows转移兼容性
|
||||
// 转移过滤器、选择器 David/2020年7月11日
|
||||
$path_filter = isset($configALL['default']['move']['path_filter']) && !empty($configALL['default']['move']['path_filter']) ? $configALL['default']['move']['path_filter'] : null;
|
||||
$path_selector = isset($configALL['default']['move']['path_selector']) && !empty($configALL['default']['move']['path_selector']) ? $configALL['default']['move']['path_selector'] : null;
|
||||
if (\is_null($path_filter) && \is_null($path_selector)) {
|
||||
return false;
|
||||
} elseif (\is_null($path_filter)) {
|
||||
//选择器
|
||||
if (\is_array($path_selector)) {
|
||||
foreach ($path_selector as $pathName) {
|
||||
if (strpos($path, $pathName)===0) { // 没用$path == $key判断,是为了提高兼容性
|
||||
return false;
|
||||
}
|
||||
}
|
||||
$url = $_url."&passkey=". $configALL[$site]['passkey'] . $ip_type. "&https=1";
|
||||
break;
|
||||
case 'ccfbits':
|
||||
$url = str_replace('{passkey}', $configALL[$site]['passkey'], $_url);
|
||||
break;
|
||||
case 'dicmusic':
|
||||
$_url = str_replace('{torrent_pass}', $configALL[$site]['passkey'], $_url);
|
||||
$url = str_replace('{authkey}', $configALL[$site]['authkey'], $_url);
|
||||
break;
|
||||
default:
|
||||
$url = $_url."&passkey=". $configALL[$site]['passkey'];
|
||||
break;
|
||||
echo '已跳过!转移选择器未匹配到:'.$path.PHP_EOL;
|
||||
return true;
|
||||
}
|
||||
} elseif (\is_null($path_selector)) {
|
||||
//过滤器
|
||||
if (\is_array($path_filter)) {
|
||||
foreach ($path_filter as $pathName) {
|
||||
if (strpos($path, $pathName)===0) { // 没用$path == $key判断,是为了提高兼容性
|
||||
echo '已跳过!转移过滤器匹配到:'.$path.PHP_EOL;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
//同时设置过滤器、选择器
|
||||
if (\is_array($path_selector) && \is_array($path_filter)) {
|
||||
//先过滤器
|
||||
foreach ($path_filter as $pathName) {
|
||||
if (strpos($path, $pathName)===0) {
|
||||
echo '已跳过!转移过滤器匹配到:'.$path.PHP_EOL;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
//后选择器
|
||||
foreach ($path_selector as $pathName) {
|
||||
if (strpos($path, $pathName)===0) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
echo '已跳过!转移选择器未匹配到:'.$path.PHP_EOL;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取站点种子的URL
|
||||
* @param string $site
|
||||
* @param string $url
|
||||
* @return string
|
||||
*/
|
||||
private static function getTorrentUrl($site = '', $url = '')
|
||||
{
|
||||
global $configALL;
|
||||
// 兼容旧配置
|
||||
if (isset($configALL[$site]['passkey']) && $configALL[$site]['passkey']) {
|
||||
if (empty($configALL[$site]['url_replace'])) {
|
||||
$configALL[$site]['url_replace'] = array('{passkey}' => $configALL[$site]['passkey']);
|
||||
}
|
||||
if (empty($configALL[$site]['url_join'])) {
|
||||
$configALL[$site]['url_join'] = array();
|
||||
if (in_array($site, array('m-team','mocat','hdbd'))) {
|
||||
if (isset($configALL[$site]['ip_type'])) {
|
||||
$configALL[$site]['url_join'][] = $configALL[$site]['ip_type'].'=1';
|
||||
}
|
||||
$configALL[$site]['url_join'][] = 'https=1';
|
||||
}
|
||||
}
|
||||
}
|
||||
// 通用操作:替换
|
||||
if (isset($configALL[$site]['url_replace']) && $configALL[$site]['url_replace']) {
|
||||
$url = strtr($url, $configALL[$site]['url_replace']);
|
||||
}
|
||||
// 通用操作:拼接
|
||||
if (isset($configALL[$site]['url_join']) && $configALL[$site]['url_join']) {
|
||||
$url = $url.(strpos($url, '?') === false ? '?' : '&').implode('&', $configALL[$site]['url_join']);
|
||||
}
|
||||
return $url;
|
||||
}
|
||||
/**
|
||||
* 微信模板消息拼接方法
|
||||
*/
|
||||
public static function wechatMessage()
|
||||
private static function wechatMessage()
|
||||
{
|
||||
$br = PHP_EOL;
|
||||
$text = 'IYUU自动辅种-统计报表';
|
||||
$desp = '总做种:'.self::$wechatMsg['hashCount'] . ' [客户端正在做种的hash总数]' .$br;
|
||||
$desp .= '返回数据:'.self::$wechatMsg['reseedCount']. ' [服务器返回的可辅种数据]' .$br;
|
||||
$desp .= '支持站点:'.self::$wechatMsg['sitesCount']. ' [当前支持自动辅种的站点数量]' .$br;
|
||||
$desp .= '成功:'.self::$wechatMsg['reseedSuccess']. ' [辅种成功,会把hash加入缓存]' .$br;
|
||||
$desp .= '失败:'.self::$wechatMsg['reseedError']. ' [下载器下载种子失败或网络超时引起,可以重试]' .$br;
|
||||
$desp .= '重复:'.self::$wechatMsg['reseedRepeat']. ' [客户端已做种]' .$br;
|
||||
$desp .= '跳过:'.self::$wechatMsg['reseedSkip']. ' [未设置passkey]' .$br;
|
||||
$desp .= '忽略:'.self::$wechatMsg['reseedPass']. ' [成功添加存在缓存]' .$br;
|
||||
$desp = '### 版本号:'. self::VER . $br;
|
||||
$desp .= '**支持站点:'.self::$wechatMsg['sitesCount']. '** [当前支持自动辅种的站点数量]' .$br;
|
||||
$desp .= '**总做种:'.self::$wechatMsg['hashCount'] . '** [客户端做种的hash总数]' .$br;
|
||||
$desp .= '**返回数据:'.self::$wechatMsg['reseedCount']. '** [服务器返回的可辅种数据]' .$br;
|
||||
$desp .= '**成功:'.self::$wechatMsg['reseedSuccess']. '** [会把hash加入辅种缓存]' .$br;
|
||||
$desp .= '**失败:'.self::$wechatMsg['reseedError']. '** [种子下载失败或网络超时引起]' .$br;
|
||||
$desp .= '**重复:'.self::$wechatMsg['reseedRepeat']. '** [客户端已做种]' .$br;
|
||||
$desp .= '**跳过:'.self::$wechatMsg['reseedSkip']. '** [未设置passkey]' .$br;
|
||||
$desp .= '**忽略:'.self::$wechatMsg['reseedPass']. '** [成功添加存在缓存]' .$br;
|
||||
$desp .= '**如需重新辅种,请删除 ./torrent/cachehash 辅种缓存。**'.$br;
|
||||
// 移动做种
|
||||
if (self::$wechatMsg['MoveSuccess'] || self::$wechatMsg['MoveError']) {
|
||||
$desp .= $br.'----------'.$br;
|
||||
$desp .= '**移动成功:'.self::$wechatMsg['MoveSuccess']. '** [会把hash加入移动缓存]' .$br;
|
||||
$desp .= '**移动失败:'.self::$wechatMsg['MoveError']. '** [解决错误提示,可以重试]' .$br;
|
||||
$desp .= '**如需重新移动,请删除 ./torrent/cachemove 移动缓存。**'.$br;
|
||||
}
|
||||
$desp .= $br.'*此消息将在3天后过期*。';
|
||||
return ff($text, $desp);
|
||||
}
|
||||
/**
|
||||
@@ -762,7 +899,7 @@ class AutoReseed
|
||||
$res = self::$curl->get(self::$apiUrl.self::$endpoints['notify'].'?'.$notify);
|
||||
$res = json_decode($res->response, true);
|
||||
if (isset($res['data']['success']) && $res['data']['success']) {
|
||||
echo '感谢您的参与,种子被删除,上报成功!!'.PHP_EOL;
|
||||
echo '感谢您的参与,失效种子上报成功!!'.PHP_EOL;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@@ -788,5 +925,6 @@ class AutoReseed
|
||||
$file_pointer = @fopen($myfile, "w");
|
||||
$worldsnum = @fwrite($file_pointer, $json);
|
||||
@fclose($file_pointer);
|
||||
return $worldsnum;
|
||||
}
|
||||
}
|
||||
|
@@ -82,7 +82,7 @@ class qBittorrent extends AbstractClient
|
||||
$this->api_version = $api_version;
|
||||
$this->curl = new Curl();
|
||||
$this->curl->setOpt(CURLOPT_SSL_VERIFYPEER, false); // 禁止验证证书
|
||||
$this->curl->setOpt(CURLOPT_SSL_VERIFYHOST, false); // 不检查证书
|
||||
$this->curl->setOpt(CURLOPT_SSL_VERIFYHOST, 2); // 不检查证书
|
||||
$this->curl->setOpt(CURLOPT_CONNECTTIMEOUT, 60); // 超时
|
||||
$this->curl->setOpt(CURLOPT_TIMEOUT, 600); // 超时
|
||||
// Authenticate and get cookie, else throw exception
|
||||
|
@@ -1,9 +1,4 @@
|
||||
<?php
|
||||
/**
|
||||
* @brief 文件处理
|
||||
* @version 0.6
|
||||
*/
|
||||
|
||||
namespace IYUU\Library;
|
||||
|
||||
/**
|
||||
@@ -13,7 +8,6 @@ namespace IYUU\Library;
|
||||
class IFile
|
||||
{
|
||||
private $resource = null; //文件资源句柄
|
||||
|
||||
/**
|
||||
* @brief 构造函数,打开资源流,并独占锁定
|
||||
* @param String $fileName 文件路径名
|
||||
|
@@ -1,15 +1,15 @@
|
||||
<?php
|
||||
/**
|
||||
* IYUU用户注册、认证
|
||||
*/
|
||||
namespace IYUU\Library;
|
||||
|
||||
use Curl\Curl;
|
||||
|
||||
/**
|
||||
* IYUU用户注册、认证
|
||||
*/
|
||||
class Oauth
|
||||
{
|
||||
// 合作的站点
|
||||
public static $sites = ['ourbits','hddolby','hdhome','pthome'];
|
||||
public static $sites = ['ourbits','hddolby','hdhome','pthome','moecat'];
|
||||
// 爱语飞飞token
|
||||
public static $token = '';
|
||||
// 合作站点用户id
|
||||
@@ -48,7 +48,7 @@ class Oauth
|
||||
$ret = false;
|
||||
self::$token = self::getSign();
|
||||
foreach (self::$sites as $name) {
|
||||
if (is_file(str_replace('{}', $name, self::$SiteLoginCache))){
|
||||
if (is_file(str_replace('{}', $name, self::$SiteLoginCache))) {
|
||||
// 存在鉴权缓存
|
||||
$ret = true;
|
||||
continue;
|
||||
@@ -69,11 +69,11 @@ class Oauth
|
||||
$res = $curl->get($apiUrl, $data);
|
||||
p($res->response);
|
||||
|
||||
$rs = json_decode($res->response,true);
|
||||
if (isset($rs['ret']) && $rs['ret'] == 200 && isset($rs['data']['success']) && $rs['data']['success']){
|
||||
$rs = json_decode($res->response, true);
|
||||
if (isset($rs['ret']) && $rs['ret'] == 200 && isset($rs['data']['success']) && $rs['data']['success']) {
|
||||
self::setSiteLoginCache($name, $rs);
|
||||
$ret = true;
|
||||
}else{
|
||||
} else {
|
||||
$msg = isset($rs['msg']) && $rs['msg'] ? $rs['msg'] : '远端服务器无响应,请稍后重试!';
|
||||
$msg = isset($rs['data']['errmsg']) && $rs['data']['errmsg'] ? $rs['data']['errmsg'] : $msg;
|
||||
echo $msg . PHP_EOL;
|
||||
@@ -86,7 +86,8 @@ class Oauth
|
||||
return $ret;
|
||||
}
|
||||
/**
|
||||
* 写鉴权成功配置
|
||||
* 写鉴权成功缓存
|
||||
* @desc 作用:减少对服务器请求,跳过鉴权提示信息;
|
||||
*/
|
||||
private static function setSiteLoginCache($key = '', $array = [])
|
||||
{
|
||||
|
@@ -1,54 +1,47 @@
|
||||
<?php
|
||||
namespace IYUU\Library;
|
||||
|
||||
/**
|
||||
* Created by PhpStorm.
|
||||
* User: 大卫
|
||||
* Date: 2020-1-19
|
||||
* Time: 17:44
|
||||
*/
|
||||
namespace IYUU\Library;
|
||||
|
||||
class Table
|
||||
{
|
||||
const ALIGN_LEFT = 1;
|
||||
const ALIGN_RIGHT = 0;
|
||||
const ALIGN_CENTER = 2;
|
||||
|
||||
/**
|
||||
* 头信息数据
|
||||
* @var array
|
||||
*/
|
||||
protected $header = [];
|
||||
|
||||
/**
|
||||
* 头部对齐方式 默认1 ALGIN_LEFT 0 ALIGN_RIGHT 2 ALIGN_CENTER
|
||||
* @var int
|
||||
*/
|
||||
protected $headerAlign = 1;
|
||||
|
||||
/**
|
||||
* 表格数据(二维数组)
|
||||
* @var array
|
||||
*/
|
||||
protected $rows = [];
|
||||
|
||||
/**
|
||||
* 单元格对齐方式 默认1 ALGIN_LEFT 0 ALIGN_RIGHT 2 ALIGN_CENTER
|
||||
* @var int
|
||||
*/
|
||||
protected $cellAlign = 1;
|
||||
|
||||
/**
|
||||
* 单元格宽度信息
|
||||
* @var array
|
||||
*/
|
||||
protected $colWidth = [];
|
||||
|
||||
/**
|
||||
* 表格输出样式
|
||||
* @var string
|
||||
*/
|
||||
protected $style = 'default';
|
||||
|
||||
/**
|
||||
* 表格样式定义
|
||||
* @var array
|
||||
|
@@ -1,5 +1,4 @@
|
||||
<?php
|
||||
|
||||
use IYUU\Library\IFile;
|
||||
use IYUU\Library\Table;
|
||||
|
||||
|
24
backup.sh
Normal file
24
backup.sh
Normal file
@@ -0,0 +1,24 @@
|
||||
#!/bin/sh
|
||||
# 传入的种子备份参数
|
||||
if [ $1 ]; then
|
||||
AppName=$1
|
||||
fi
|
||||
|
||||
if [ $2 ]; then
|
||||
torrentDir=$2
|
||||
fi
|
||||
|
||||
# 脚本当前目录
|
||||
pwddir=$(cd $(dirname $0); pwd)
|
||||
# 当前日期
|
||||
DATE=$(date +%Y%m%d)
|
||||
# 备份在当前目录
|
||||
backupdir=$pwddir"/"$AppName$DATE
|
||||
echo "种子备份目录:"$backupdir
|
||||
mkdir $backupdir -p
|
||||
# 种子目录
|
||||
torrentDir=$torrentDir"/*"
|
||||
# 备份
|
||||
cp -rf $torrentDir $backupdir
|
||||
# 成功提示
|
||||
echo "ok";
|
@@ -2,10 +2,11 @@
|
||||
/**
|
||||
* 技术讨论及后续更新,请加入QQ群!!!!!!!
|
||||
群名称:IYUU自动辅种交流
|
||||
QQ群号:859882209
|
||||
QQ群号:859882209、931954050
|
||||
* IYUU自动辅种工具-【安装篇】如何下载最新源码? https://www.iyuu.cn/archives/338/
|
||||
* IYUU自动辅种工具-【安装篇】Windows之git https://www.iyuu.cn/archives/367/
|
||||
* IYUU自动辅种工具-【安装篇】群晖Linux之git https://www.iyuu.cn/archives/372/
|
||||
* IYUU自动辅种工具-【安装篇】小钢炮手把手教程 https://www.iyuu.cn/archives/386/
|
||||
* IYUU自动辅种工具--最简配置(所有平台通用教程) https://www.iyuu.cn/archives/324/
|
||||
* IYUU自动辅种工具--合作站点鉴权配置说明 https://www.iyuu.cn/archives/337/
|
||||
* IYUU自动下载种子--之RSS订阅使用教程 https://www.iyuu.cn/archives/349/
|
||||
@@ -18,15 +19,11 @@
|
||||
return array(
|
||||
// 1.【必须配置】爱语飞飞 微信通知,请访问https://iyuu.cn 用微信扫码申请
|
||||
'iyuu.cn' => 'IYUU',
|
||||
// 2.server酱 微信通知配置
|
||||
'sc.ftqq.com' => '',
|
||||
// 3.发布员鉴权
|
||||
'secret' => '',
|
||||
// 4.全局默认配置
|
||||
// 2.全局默认配置
|
||||
'default' => array(
|
||||
// 5.【必须配置】浏览器UA,打开http://demo.iyuu.cn 复制过来即可
|
||||
// 3.【必须配置】浏览器UA,打开http://demo.iyuu.cn 复制过来即可
|
||||
'userAgent' => 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.1303.189 Safari/537.36',
|
||||
// 6.【自动辅种必须配置】全局客户端设置(条目不够可以复制)
|
||||
// 4.【自动辅种必须配置】全局客户端设置(条目不够可以复制)
|
||||
'clients' => array(
|
||||
// 全局客户端设置 开始
|
||||
# 开始
|
||||
@@ -36,7 +33,7 @@ return array(
|
||||
'username' => '',
|
||||
'password' => '',
|
||||
'BT_backup' => '/var/lib/transmission/torrents', // 移动做种:如果脚本与当前客户端不在一台机器,必须配置
|
||||
'move' => 0, // 0不移动,1移动并辅种,2移动仅辅种自身,3未定义
|
||||
'move' => 0, // 0不移动,1移动并辅种,2移动且只在当前客户端辅种
|
||||
),
|
||||
# 结束
|
||||
# 开始
|
||||
@@ -45,25 +42,31 @@ return array(
|
||||
'host' => 'http://127.0.0.1:8083',
|
||||
'username' => '',
|
||||
'password' => '',
|
||||
'root_folder'=> 1, // 0不创建根目录,1创建根目录
|
||||
'BT_backup' => 'C:\Users\ASUS\AppData\Local\qBittorrent\BT_backup', // 移动做种:必须配置,Linux搜索方法:find / -name BT_backup
|
||||
'move' => 0, // 0不移动,1移动并辅种,2移动仅辅种自身,3未定义
|
||||
'move' => 0, // 0不移动,1移动并辅种,2移动且只在当前客户端辅种
|
||||
),
|
||||
# 结束
|
||||
// 全局客户端设置 结束
|
||||
),
|
||||
// 移动做种必须配置
|
||||
// 5.移动做种必须配置
|
||||
'move' =>array(
|
||||
'type' => 0, // 0保持不变,1减,2加,3替换
|
||||
'path' =>array(
|
||||
// 当前路径 => 目标路径
|
||||
'/downloads' => '/volume1',
|
||||
),
|
||||
'path_filter'=> array(), //转移过滤器:不转移此路径内文件
|
||||
'path_selector' => array(), //转移选择器:只转移此路径内文件(为空时,全转移) 【优先级:过滤器 > 选择器】
|
||||
'paused' => 0, //转移成功,自动开始任务:0开始,1暂停
|
||||
'skip_check' => 0, //转移成功,跳校验:0不跳、1跳校验
|
||||
'delete_torrent' => 0, //转移成功,删除当前做种:0不删除、1删除
|
||||
),
|
||||
// 6.RSS工作模式
|
||||
'workingMode' => 0,
|
||||
// 7.监控目录
|
||||
'watch' => '/volume1/downloads',
|
||||
// 8.RSS过滤参数配置
|
||||
'filter' => array(
|
||||
'size'=>array(
|
||||
'min' => '1GB',
|
||||
@@ -85,6 +88,10 @@ return array(
|
||||
'CONNECTTIMEOUT'=> 60,
|
||||
'TIMEOUT' => 600,
|
||||
),
|
||||
// 9.server酱 微信通知配置
|
||||
'sc.ftqq.com' => '',
|
||||
// 10.发布员鉴权
|
||||
'secret' => '',
|
||||
/**
|
||||
* 以下为各站点的独立配置(互不影响、互不冲突)
|
||||
* 自动辅种:需要配置各站的passkey(没有配置passkey的站点会自动跳过)
|
||||
@@ -104,6 +111,11 @@ return array(
|
||||
'max' => '280GB',
|
||||
),
|
||||
),
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(
|
||||
//'ipv6=1', // 种子Tracker的IP地址选择 可选:ipv4,ipv6
|
||||
//'https=1',
|
||||
),
|
||||
),
|
||||
// hddolby
|
||||
'hddolby' => array(
|
||||
@@ -112,6 +124,8 @@ return array(
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'id' => 0, // 用户ID(不是用户名)
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdhome
|
||||
'hdhome' => array(
|
||||
@@ -120,6 +134,8 @@ return array(
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'id' => 0, // 用户ID(不是用户名)
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// PTHome
|
||||
'pthome' => array(
|
||||
@@ -128,6 +144,21 @@ return array(
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'id' => 0, // 用户ID(不是用户名)
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// MoeCat
|
||||
'moecat' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'id' => 0, // 用户ID(不是用户名)
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(
|
||||
//'ipv6=1', // 种子Tracker的IP地址选择 可选:ipv4,ipv6
|
||||
//'https=1',
|
||||
),
|
||||
),
|
||||
// m-team
|
||||
'm-team' => array(
|
||||
@@ -135,8 +166,11 @@ return array(
|
||||
'cookie' => 'tp=',
|
||||
// 15.m-team的passkey 【必须配置】
|
||||
'passkey' => '',
|
||||
// 种子Tracker的IP地址选择 可选:ipv4,ipv6
|
||||
'ip_type' => 'ipv4',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(
|
||||
//'ipv6=1', // 种子Tracker的IP地址选择 可选:ipv4,ipv6
|
||||
'https=1',
|
||||
),
|
||||
'clients' => array(
|
||||
array(
|
||||
'type' => 'transmission', // 支持:transmission、qBittorrent
|
||||
@@ -161,6 +195,8 @@ return array(
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
'workingMode' => 1,
|
||||
'watch' => '',
|
||||
'filter' => array(
|
||||
@@ -176,6 +212,8 @@ return array(
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// tjupt
|
||||
'tjupt' => array(
|
||||
@@ -183,6 +221,8 @@ return array(
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// btschool
|
||||
'btschool' => array(
|
||||
@@ -190,6 +230,8 @@ return array(
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// HDSky
|
||||
'hdsky' => array(
|
||||
@@ -197,6 +239,12 @@ return array(
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'limitRule' => array(
|
||||
'count' => 50, // 每次辅种50个
|
||||
'sleep' => 15, // 最少休眠15秒
|
||||
),
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// TorrentCCF
|
||||
'torrentccf' => array(
|
||||
@@ -204,6 +252,8 @@ return array(
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// PTMSG
|
||||
'ptmsg' => array(
|
||||
@@ -211,15 +261,8 @@ return array(
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
),
|
||||
// MoeCat
|
||||
'moecat' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
// 种子Tracker的IP地址选择 可选:ipv4,ipv6
|
||||
'ip_type' => 'ipv4',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// totheglory
|
||||
'ttg' => array(
|
||||
@@ -228,6 +271,8 @@ return array(
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
// 如果需要rss订阅,必须配置
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
'rss' => '',
|
||||
),
|
||||
// nanyangpt
|
||||
@@ -236,6 +281,8 @@ return array(
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// springsunday.net
|
||||
'ssd' => array(
|
||||
@@ -243,238 +290,335 @@ return array(
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// yingk 序号:17
|
||||
// yingk
|
||||
'yingk' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdcity 序号:18
|
||||
// hdcity
|
||||
'hdcity' => array(
|
||||
// 必须配置
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置cuhash
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// 52pt.site 序号:19
|
||||
// 52pt.site
|
||||
'52pt' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// brobits.cc 序号:20
|
||||
// brobits
|
||||
'brobits' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// www.beitai.pt 序号:21
|
||||
// beitai
|
||||
'beitai' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// pt.eastgame.org 序号:22
|
||||
// eastgame
|
||||
'eastgame' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// pt.soulvoice.club 序号:23
|
||||
// soulvoice
|
||||
'soulvoice' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// chdbits 序号:24
|
||||
// chdbits
|
||||
'chdbits' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// leaguehd 序号:25
|
||||
// leaguehd
|
||||
'leaguehd' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// ptsbao.club 序号:26
|
||||
// ptsbao
|
||||
'ptsbao' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdchina 序号:27
|
||||
// hdchina
|
||||
'hdchina' => array(
|
||||
// 必须配置
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdarea 序号:28
|
||||
// hdarea
|
||||
'hdarea' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdtime 序号:29
|
||||
// hdtime
|
||||
'hdtime' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// 1ptba 序号:30
|
||||
// 1ptba
|
||||
'1ptba' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hd4fans 序号:31
|
||||
// hd4fans
|
||||
'hd4fans' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hddisk.life 序号:32
|
||||
// hddisk.life
|
||||
'hdbug' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// opencd 序号:33 皇后
|
||||
// opencd皇后
|
||||
'opencd' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdstreet 序号:34
|
||||
// hdstreet
|
||||
'hdstreet' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// joyhd 序号:35
|
||||
// joyhd
|
||||
'joyhd' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// dmhy 序号:36 幼儿园
|
||||
// dmhy幼儿园
|
||||
'dmhy' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdu 序号:37
|
||||
// hdu
|
||||
'upxin' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// oshen 序号:38
|
||||
// oshen
|
||||
'oshen' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// discfan 序号:39 港知堂
|
||||
// discfan港知堂
|
||||
'discfan' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdzone 序号:40
|
||||
// hdzone
|
||||
'hdzone' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// nicept 序号:42 老师
|
||||
// nicept老师
|
||||
'nicept' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdbd 序号:43 伊甸园
|
||||
// hdbd伊甸园
|
||||
'hdbd' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(
|
||||
//'ipv6=1', // 种子Tracker的IP地址选择 可选:ipv4,ipv6
|
||||
//'https=1',
|
||||
),
|
||||
),
|
||||
// byr 序号:44 北邮
|
||||
// byr北邮
|
||||
'byr' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// CCFBits 序号:45
|
||||
// CCFBits
|
||||
'ccfbits' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdbits 序号:46
|
||||
// hdbits
|
||||
'hdbits' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// PTPBD 序号:47
|
||||
// PTPBD
|
||||
'ptpbd' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// HD-T 序号:48
|
||||
// HD-T
|
||||
'hd-torrents' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// skyeysnow 序号:50 天雪
|
||||
// skyeysnow天雪
|
||||
'skyeysnow' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// pt.sjtu 序号:51 葡萄
|
||||
// pt.sjtu葡萄
|
||||
'pt' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
|
||||
// 配置文件结束
|
||||
// hdroute
|
||||
'hdroute' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// haidan
|
||||
'haidan' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// hdfans
|
||||
'hdfans' => array(
|
||||
// 如果需要用下载免费种脚本,须配置(只是自动辅种,可以不配置此项)
|
||||
'cookie' => '',
|
||||
// 如果需要自动辅种,必须配置
|
||||
'passkey' => '',
|
||||
'url_replace' => array(),
|
||||
'url_join' => array(),
|
||||
),
|
||||
// 配置结束,后面的一行不能删除,必须保留!!!
|
||||
);
|
||||
|
@@ -1,17 +1,36 @@
|
||||
# IYUUAutoReseed自动辅种docker安装教程
|
||||
|
||||
第一步:复制docker目录到您的Linux的任意目录内;
|
||||
### 教程地址:https://www.iyuu.cn/archives/386/
|
||||
|
||||
第二步:给予`build.sh`、`iyuu.sh`可执行权限;
|
||||
### 命令行安装步骤:
|
||||
|
||||
第三步:编译镜像并运行容器,命令为:`./build.sh` 耐心等待完成;
|
||||
```sh
|
||||
cd /root
|
||||
git clone https://gitee.com/ledc/IYUUAutoReseed.git
|
||||
cd /root/IYUUAutoReseed/docker
|
||||
chmod +x ./*.sh
|
||||
./build.sh
|
||||
./iyuu.sh
|
||||
```
|
||||
|
||||
第四步:测试是否安装完成,命令为:`./iyuu.sh`
|
||||
|
||||
然后看教程:https://www.iyuu.cn/archives/324/,来编辑配置即可。
|
||||
|
||||
#### 必读:脚本会在`/root`目录,创建`IYUUAutoReseed`文件夹,您只需要按照上述教程编辑好配置,放到`/root/IYUUAutoReseed/config/config.php`
|
||||
### 命令解释:
|
||||
|
||||
第一步:进入`/root`目录内;
|
||||
|
||||
第二步:通过git命令,拉取最新辅种脚本代码;
|
||||
|
||||
第三步:进入`/root/IYUUAutoReseed/docker`目录
|
||||
|
||||
第四步:给予`build.sh`、`iyuu.sh`可执行权限;
|
||||
|
||||
第五步:编译镜像并运行容器,请耐心等待完成;
|
||||
|
||||
第六步:测试是否安装完成,命令为:`./iyuu.sh`
|
||||
|
||||
做完以上步骤,确认没问题后,然后看教程:https://www.iyuu.cn/archives/324/,来编辑配置即可。
|
||||
脚本会在`/root`目录,创建`IYUUAutoReseed`文件夹,您只需要按照上述教程编辑好配置,放到`/root/IYUUAutoReseed/config/config.php`
|
||||
|
||||
|
||||
### 辅种时执行的命令:`iyuu.sh`
|
||||
|
@@ -1,6 +1,9 @@
|
||||
#!/bin/sh
|
||||
cd /root
|
||||
wget -c https://gitee.com/ledc/IYUUAutoReseed/repository/archive/master.zip -O IYUUAutoReseed.zip
|
||||
unzip -o ./IYUUAutoReseed.zip -d /root
|
||||
rm ./IYUUAutoReseed.zip
|
||||
cd /root/IYUUAutoReseed/docker
|
||||
chmod +x ./*.sh
|
||||
docker build -t iyuu:latest .
|
||||
docker run -it -v /root/IYUUAutoReseed:/var/www -p 8510:9000 --network bridge --name IYUUAutoReseed --restart always -d iyuu:latest
|
||||
|
8
docker/n1.sh
Normal file
8
docker/n1.sh
Normal file
@@ -0,0 +1,8 @@
|
||||
#!/bin/sh
|
||||
cd /root
|
||||
git clone https://gitee.com/ledc/IYUUAutoReseed.git
|
||||
cd /root/IYUUAutoReseed/docker
|
||||
chmod +x ./*.sh
|
||||
docker build -t iyuu:latest .
|
||||
docker run -it -v /root/IYUUAutoReseed:/var/www -v /var/lib/qbittorrent/.local/share/data/qBittorrent/BT_backup:/BT_backup -p 8510:9000 --network bridge --name IYUUAutoReseed --restart always -d iyuu:latest
|
||||
./iyuu.sh
|
@@ -1,4 +1,9 @@
|
||||
#!/bin/sh
|
||||
#脚本功能:从git拉取最新代码,然后执行辅种
|
||||
pwddir=$(cd $(dirname $0); pwd)
|
||||
echo $pwddir
|
||||
cd $(dirname $0)
|
||||
git fetch --all
|
||||
git reset --hard origin/master
|
||||
git pull
|
||||
php ./iyuu.php
|
28
init.php
28
init.php
@@ -1,23 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
|
||||
|
||||
IIIIIIIIIIYYYYYYY YYYYYYYUUUUUUUU UUUUUUUUUUUUUUUU UUUUUUUU
|
||||
I::::::::IY:::::Y Y:::::YU::::::U U::::::UU::::::U U::::::U
|
||||
I::::::::IY:::::Y Y:::::YU::::::U U::::::UU::::::U U::::::U
|
||||
II::::::IIY::::::Y Y::::::YUU:::::U U:::::UUUU:::::U U:::::UU
|
||||
I::::I YYY:::::Y Y:::::YYY U:::::U U:::::U U:::::U U:::::U
|
||||
I::::I Y:::::Y Y:::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::Y:::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::Y U::::::U U::::::U U::::::U U::::::U
|
||||
II::::::II Y:::::Y U:::::::UUU:::::::U U:::::::UUU:::::::U
|
||||
I::::::::I YYYY:::::YYYY UU:::::::::::::UU UU:::::::::::::UU
|
||||
I::::::::I Y:::::::::::Y UU:::::::::UU UU:::::::::UU
|
||||
IIIIIIIIII YYYYYYYYYYYYY UUUUUUUUU UUUUUUUUU
|
||||
|
||||
I::::I YYY:::::Y Y:::::YYY U:::::U U:::::U U:::::U U:::::U
|
||||
I::::I Y:::::Y Y:::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::Y:::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::Y U:::::D D:::::U U:::::D D:::::U
|
||||
I::::I Y:::::Y U::::::U U::::::U U::::::U U::::::U
|
||||
II::::::II Y:::::Y U:::::::UUU:::::::U U:::::::UUU:::::::U
|
||||
I::::::::I YYYY:::::YYYY UU:::::::::::::UU UU:::::::::::::UU
|
||||
I::::::::I Y:::::::::::Y UU:::::::::UU UU:::::::::UU
|
||||
IIIIIIIIII YYYYYYYYYYYYY UUUUUUUUU UUUUUUUUU
|
||||
|
||||
*/
|
||||
// 定义目录
|
||||
defined('ROOT_PATH') or define("ROOT_PATH", __DIR__);
|
||||
|
42
iyuu.php
42
iyuu.php
@@ -1,34 +1,32 @@
|
||||
<?php
|
||||
/**
|
||||
_____ _____ _____ _____
|
||||
/\ \ |\ \ /\ \ /\ \
|
||||
/::\ \ |:\____\ /::\____\ /::\____\
|
||||
\:::\ \ |::| | /:::/ / /:::/ /
|
||||
\:::\ \ |::| | /:::/ / /:::/ /
|
||||
\:::\ \ |::| | /:::/ / /:::/ /
|
||||
\:::\ \ |::| | /:::/ / /:::/ /
|
||||
/::::\ \ |::| | /:::/ / /:::/ /
|
||||
____ /::::::\ \ |::|___|______ /:::/ / _____ /:::/ / _____
|
||||
/\ \ /:::/\:::\ \ /::::::::\ \ /:::/____/ /\ \ /:::/____/ /\ \
|
||||
_____ _____ _____ _____
|
||||
/\ \ |\ \ /\ \ /\ \
|
||||
/::\ \ |:\____\ /::\____\ /::\____\
|
||||
\:::\ \ |::| | /:::/ / /:::/ /
|
||||
\:::\ \ |::| | /:::/ / /:::/ /
|
||||
\:::\ \ |::| | /:::/ / /:::/ /
|
||||
\:::\ \ |::| | /:::/ / /:::/ /
|
||||
/::::\ \ |::| | /:::/ / /:::/ /
|
||||
____ /::::::\ \ |::|___|______ /:::/ / _____ /:::/ / _____
|
||||
/\ \ /:::/\:::\ \ /::::::::\ \ /:::/____/ /\ \ /:::/____/ /\ \
|
||||
/::\ \/:::/ \:::\____\ /::::::::::\____\|:::| / /::\____\|:::| / /::\____\
|
||||
\:::\ /:::/ \::/ / /:::/~~~~/~~ |:::|____\ /:::/ /|:::|____\ /:::/ /
|
||||
\:::\/:::/ / \/____/ /:::/ / \:::\ \ /:::/ / \:::\ \ /:::/ /
|
||||
\::::::/ / /:::/ / \:::\ \ /:::/ / \:::\ \ /:::/ /
|
||||
\::::/____/ /:::/ / \:::\ /:::/ / \:::\ /:::/ /
|
||||
\:::\ \ \::/ / \:::\__/:::/ / \:::\__/:::/ /
|
||||
\:::\ \ \/____/ \::::::::/ / \::::::::/ /
|
||||
\:::\ \ \::::::/ / \::::::/ /
|
||||
\:::\____\ \::::/ / \::::/ /
|
||||
\::/ / \::/____/ \::/____/
|
||||
\/____/ ~~ ~~
|
||||
\:::\/:::/ / \/____/ /:::/ / \:::\ \ /:::/ / \:::\ \ /:::/ /
|
||||
\::::::/ / /:::/ / \:::\ \ /:::/ / \:::\ \ /:::/ /
|
||||
\::::/____/ /:::/ / \:::\ /:::/ / \:::\ /:::/ /
|
||||
\:::\ \ \::/ / \:::\__/:::/ / \:::\__/:::/ /
|
||||
\:::\ \ \/____/ \::::::::/ / \::::::::/ /
|
||||
\:::\ \ \::::::/ / \::::::/ /
|
||||
\:::\____\ \::::/ / \::::/ /
|
||||
\::/ / \::/____/ \::/____/
|
||||
\/____/ ~~ ~~
|
||||
*/
|
||||
|
||||
require_once __DIR__ . '/init.php';
|
||||
echo __FILE__.PHP_EOL;
|
||||
sleep(1);
|
||||
echo '当前脚本路径:'.__FILE__.PHP_EOL;
|
||||
use IYUU\AutoReseed;
|
||||
|
||||
echo microtime(true).' IYUU自动辅种正在初始化...'.PHP_EOL;
|
||||
AutoReseed::init();
|
||||
AutoReseed::call();
|
||||
exit(0);
|
||||
|
41
readme.md
41
readme.md
@@ -10,7 +10,7 @@
|
||||
|
||||
第三:您使用IYUU工具造成的一切损失,与IYUU无关。如不接受此条款,请不要使用IYUUAutoReseed,并立刻删除已经下载的源码。
|
||||
|
||||
## 安装脚本,三种方式皆可
|
||||
## 获取脚本,三种方式皆可
|
||||
|
||||
1. 通过git命令安装
|
||||
|
||||
@@ -26,52 +26,58 @@
|
||||
|
||||
## 功能
|
||||
|
||||
IYUU自动辅种工具,目前能对国内大部分的PT站点自动辅种,支持下载器集群,支持多盘位,支持多下载目录,支持远程连接等。
|
||||
IYUU自动辅种工具,功能分为两大块:自动辅种、自动转移。
|
||||
|
||||
- 自动辅种:目前能对国内大部分的PT站点自动辅种,支持下载器集群,支持多盘位,支持多下载目录,支持远程连接等;
|
||||
|
||||
- 自动转移:可以实现各下载器之间自动转移做种客户端,让下载器各司其职(专职的保种、专职的下载)。
|
||||
|
||||
## 原理
|
||||
IYUU自动辅种工具(英文名:IYUUAutoReseed),是一款PHP语言编写的Private Tracker辅种脚本,通过计划任务或常驻内存,按指定频率调用transmission、qBittorrent下载软件的API接口,提取正在做种的info_hash提交到服务器API接口,根据API接口返回的数据拼接种子连接,提交给下载器,自动辅种各个站点。
|
||||
IYUU自动辅种工具(英文名:IYUUAutoReseed),是一款PHP语言编写的Private Tracker辅种脚本,通过计划任务或常驻内存,按指定频率调用transmission、qBittorrent下载软件的API接口,提取正在做种的info_hash提交到辅种服务器API接口(辅种过程和PT站没有任何交互),根据API接口返回的数据拼接种子连接,提交给下载器,自动辅种各个站点。
|
||||
|
||||
## 优势
|
||||
- 全程自动化,无需人工干预;
|
||||
- 支持多盘位,多做种目录,多下载器,支持远程连接下载器;
|
||||
- 支持多盘位,多做种目录,多下载器,支持远程下载器;
|
||||
- 辅种精确度高,精度可配置;
|
||||
- 支持微信通知,消息即时达;
|
||||
- 自动对合集包,进行拆包辅种(暂未开发)
|
||||
- 安全:所有隐私信息只在本地存储,绝不发送给第三方。
|
||||
- 拥有专业的问答社区和交流群
|
||||
|
||||
## 支持的下载器
|
||||
1. transmission
|
||||
2. qBittorrent
|
||||
|
||||
## 支持自动辅种的站点
|
||||
学校、杜比、家园、天空、朋友、馒头、萌猫、我堡、猫站、铂金家、烧包、北洋、TCCF、南洋、TTG、映客、城市、52pt、brobits、备胎、SSD、CHD、ptmsg、leaguehd、聆音、瓷器、hdarea、eastgame(TLF)、1ptba、hdtime、hd4fans、opencd、hdbug、hdstreet、joyhd、u2、upxin(HDU)、oshen、discfan(GZT)、cnscg圣城(已删除)、北邮、CCFBits、dicmusic、天雪、葡萄。
|
||||
学校、杜比、家园、天空、朋友、馒头、萌猫、我堡、猫站、铂金家、烧包、北洋、TCCF、南洋、TTG、映客、城市、52pt、brobits、备胎、SSD、CHD、ptmsg、leaguehd、聆音、瓷器、hdarea、eastgame(TLF)、1ptba、hdtime、hd4fans、opencd、hdbug、hdstreet、joyhd、u2、upxin(HDU)、oshen、discfan(GZT)、cnscg圣城(已删除)、北邮、CCFBits、dicmusic、天雪、葡萄、HDRoute、伊甸园hdbd、海胆haidan、HDfans。
|
||||
|
||||
## 运行环境
|
||||
具备PHP运行环境的所有平台,例如:Linux、Windows、MacOS!
|
||||
|
||||
官方下载的记得开启crul、fileinfo、mbstring,这3个扩展。
|
||||
官方下载的记得开启curl、json、mbstring,这3个扩展。
|
||||
|
||||
1. Windows下安装php环境:https://www.php.net/downloads
|
||||
1. Windows安装php环境:https://www.php.net/downloads
|
||||
|
||||
|
||||
## 下载源码
|
||||
- github仓库:https://github.com/ledccn/IYUUAutoReseed
|
||||
- 码云仓库:https://gitee.com/ledc/IYUUAutoReseed
|
||||
- 仓库下载的源码,缺少vendor目录,可以去群内下载;或者通过安装php包管理器composer,进到源码目录内执行命令:`composer install`,会自动帮你安装vendor目录。
|
||||
|
||||
|
||||
## 使用方法
|
||||
详见Wiki:
|
||||
|
||||
https://gitee.com/ledc/IYUUAutoReseed/tree/master/wiki
|
||||
- 详见Wiki:https://gitee.com/ledc/IYUUAutoReseed/tree/master/wiki
|
||||
- 博客:https://www.iyuu.cn/
|
||||
|
||||
## 接口开发文档
|
||||
http://api.iyuu.cn/docs.php
|
||||
如果您懂得其他语言的开发,可以基于接口做成任何您喜欢的样子,比如手机APP,二进制包,Windows的GUI程序,浏览器插件等。欢迎分享您的作品!
|
||||
|
||||
实时更新的接口文档:http://api.iyuu.cn/docs.php
|
||||
|
||||
|
||||
## 需求提交/错误反馈
|
||||
- 点击链接加入群聊【IYUU自动辅种交流】:[https://jq.qq.com/?_wv=1027&k=5JOfOlM][1]
|
||||
- QQ群:859882209
|
||||
- QQ群:859882209[2000人.入门群],931954050[1000人.进阶群]
|
||||
- 问答社区:http://wenda.iyuu.cn
|
||||
- 博客:https://www.iyuu.cn/
|
||||
- issues: https://gitee.com/ledc/IYUUAutoReseed/issues
|
||||
|
||||
## 捐助开发者
|
||||
@@ -79,7 +85,7 @@ http://api.iyuu.cn/docs.php
|
||||
|
||||
如果喜欢,请帮忙在[Github](https://github.com/ledccn/IYUUAutoReseed)或[码云](https://gitee.com/ledc/IYUUAutoReseed)给个Star,也可以对IYUUAutoReseed进行[捐赠](https://gitee.com/ledc/IYUUAutoReseed#%E6%8D%90%E5%8A%A9%E5%BC%80%E5%8F%91%E8%80%85)哦 ^_^。
|
||||
|
||||
**您所有的打赏将用于服务器续期,增加服务的延续性。**
|
||||
**您所有的打赏将用于服务器维护及续期,增加服务的延续性。**
|
||||
|
||||
|
||||
|
||||
@@ -167,8 +173,3 @@ http://api.iyuu.cn/docs.php
|
||||
2. 所捐赠的资源不属于任何个人,而应作为项目或者开发团队的所需开销;
|
||||
3. 如果捐赠了却不希望您的名字出现在这里,可以联系我们进行相应处理;
|
||||
4. 更新有延时,如未能及时更新,可联系我。
|
||||
|
||||
|
||||
|
||||
[1]: https://jq.qq.com/?_wv=1027&k=5JOfOlM
|
||||
[2]: https://www.iyuu.cn/usr/uploads/2019/12/801558607.png
|
@@ -1,52 +0,0 @@
|
||||
## 下载最新源码的两种方法
|
||||
### 第一种:下载完整的发行版
|
||||
**github:**[GITHUB仓库 发行版][1]
|
||||
**gitee:**[码云仓库 发行版][2]
|
||||
下载**`Release.zip`**后缀的压缩包,解压缩后即可配置使用。
|
||||
|
||||
### 第二种:git clone下载源码
|
||||
**拉取源码命令,下面两个仓库都可以:**
|
||||
- github:`git clone https://github.com/ledccn/IYUUAutoReseed`
|
||||
- gitee:`git clone https://gitee.com/ledc/IYUUAutoReseed.git`
|
||||
|
||||
----------
|
||||
|
||||
|
||||
**完整命令:**
|
||||
```bash
|
||||
git clone https://github.com/ledccn/IYUUAutoReseed
|
||||
cd IYUUAutoReseed
|
||||
composer install
|
||||
php ./iyuu.php
|
||||
```
|
||||
Windows环境,完整过程演示:
|
||||
![git下载源码composer安装.png][3]
|
||||
```cmd
|
||||
E:\>git clone https://github.com/ledccn/IYUUAutoReseed
|
||||
Cloning into 'IYUUAutoReseed'...
|
||||
remote: Enumerating objects: 189, done.
|
||||
remote: Counting objects: 100% (189/189), done.
|
||||
remote: Compressing objects: 100% (120/120), done.
|
||||
Receiving objects: 97% (814/remote: Total 839 (delta 78), reused 171 (delta 64), pack-reused 650839), 380.00 KiB | 45.0R
|
||||
Receiving objects: 100% (839/839), 419.04 KiB | 50.00 KiB/s, done.
|
||||
Resolving deltas: 100% (468/468), done.
|
||||
|
||||
E:\>cd IYUUAutoReseed
|
||||
|
||||
E:\IYUUAutoReseed>composer install
|
||||
Loading composer repositories with package information
|
||||
Installing dependencies (including require-dev) from lock file
|
||||
Warning: The lock file is not up to date with the latest changes in composer.json. You may be getting outdated dependencies. Run update to update them.
|
||||
Package operations: 2 installs, 0 updates, 0 removals
|
||||
- Installing curl/curl (2.2.0): Loading from cache
|
||||
- Installing owner888/phpspider (v2.1.6): Loading from cache
|
||||
owner888/phpspider suggests installing ext-pcntl、ext-redis (For better performance. )
|
||||
Generating autoload files
|
||||
|
||||
E:\IYUUAutoReseed>
|
||||
```
|
||||
|
||||
|
||||
[1]: https://github.com/ledccn/IYUUAutoReseed/releases
|
||||
[2]: https://gitee.com/ledc/IYUUAutoReseed/releases
|
||||
[3]: https://www.iyuu.cn/usr/uploads/2020/01/314358689.png
|
53
wiki/公告栏.md
53
wiki/公告栏.md
@@ -1,5 +1,58 @@
|
||||
# 公告栏
|
||||
|
||||
### 2020年7月13日08:00:00
|
||||
|
||||
【更新提醒】v1.9.1
|
||||
|
||||
优化:App.Api.Sites接口请求时携带版本号(版本为空或低于v1.9.1会返回旧数据);
|
||||
|
||||
新增:异步间隔流控算法,适用所有站点;各站独立、执行时间最优;
|
||||
|
||||
【升级方法】
|
||||
|
||||
1.异步间隔流控使用方法:参考v1.9.1版本的config.sample.php[第242-245行],把他复制到你想应用流控的站点配置项内;解释:count表示每次辅种的最大数量,sleep表示当前站点每次下载种子最小间隔多少秒。
|
||||
|
||||
2.url_replace和url_join是为了最大化兼容未来各种类型站点提前准备的,可以自定义URL;
|
||||
|
||||
解释:url_replace是替换下载链接时使用,让下载链接支持替换任意参数。举例:'url_replace'=>array('{passkey}'=>'123456789'), 下载链接https://pt.baidu.com/download.php?id={}&passkey={passkey},替换后变为https://pt.baidu.com/download.php?id={}&passkey=123456789
|
||||
|
||||
解释:url_join是拼接下载链接是使用,让下载链接支持任意自定义参数。举例:
|
||||
'url_join' => array('ipv6=1','https=1'), 下载链接https://pt.baidu.com/download.php?id={}&passkey=123456789,拼接后变为https://pt.baidu.com/download.php?id={}&passkey=123456789&ipv6=1&https=1
|
||||
|
||||
### 2020年7月12日19:34:03
|
||||
|
||||
【新增功能】v1.9.0
|
||||
转移过滤器、选择器;可以只转移指定路径的种子,也可以排除指定路径的种子,按需转移。
|
||||
【升级方法】
|
||||
1.主脚本可以通过git pull,或覆盖更新;
|
||||
2.然后对照最新config.sample.php,把59行,60行,手动加入到你的config.php对应位置。
|
||||
|
||||
【重要提醒】域名部署SSL证书,接口域名支持双协议访问http/https,如下:
|
||||
|
||||
https://api.iyuu.cn
|
||||
|
||||
http://api.iyuu.cn
|
||||
|
||||
### 2020年4月10日17:43:50
|
||||
|
||||
针对多合作站点绑定的优化!
|
||||
1.没有更新到v1.7.5以上版本的群友,尽快更新!
|
||||
2.正在使用v1.7.5以上版本的群友,请删除config目录下的siteLoginCache_*.json文件,重新运行辅种,即可同时绑定多个合作站点。
|
||||
|
||||
### 2020年4月4日00:57:36
|
||||
|
||||
v1.7.5版本发布,新增合作站点moecat;合作站点有:Ourbits、 HD Dolby、HDHome、PTHome、moecat。【更新提醒】手动升级:可以直接覆盖!git安装的,可通过git pull命令升级!脚本升级后,然后对比config.sample.php,手动在config.php增加用户id配置项,辅种时会自动进行验证。
|
||||
如果有问题,可以群内@我或私聊,或到问答社区http://wenda.iyuu.cn/提问,必回。
|
||||
|
||||
### 2020年4月1日00:56:31
|
||||
|
||||
IYUUAutoReseed自动辅种备忘录:gitee代码仓库:https://gitee.com/ledc/IYUUAutoReseed
|
||||
github代码仓库:https://github.com/ledccn/IYUUAutoReseed
|
||||
爱语飞飞:[https://iyuu.cn](https://iyuu.cn/)
|
||||
大卫博客:[https://www.iyuu.cn](https://www.iyuu.cn/)
|
||||
问答社区:[http://wenda.iyuu.cn](http://wenda.iyuu.cn/)
|
||||
接口文档:http://api.iyuu.cn/docs.php
|
||||
|
||||
### 2020年3月14日22:03:02
|
||||
|
||||
时光如梭,转眼至v1.6.3!感谢一路走来陪伴的朋友们,为了共同的爱好我们相聚在这里!本版本上线了合作站点认证系统,合作站点有:Ourbits、 HD Dolby、HDHome。
|
||||
|
@@ -13,7 +13,8 @@
|
||||
| Google身份验证器(谷歌动态口令) | 开发中 | 2020年2月21日 | |
|
||||
| 自动更新 | 开发中 | 2020年2月21日 | |
|
||||
| WEB页面生成配置 | 开发中 | 2020年2月21日 | |
|
||||
| 种子删除自动同步 | 开发中 | 2020年2月21日 | |
|
||||
| 种子删除自动同步 | 开发中 | 2020年2月21日 | 2020年5月6日 |
|
||||
| 脚本docker容器化(测试版) | 已完成 | 2020年2月21日 | 2020年2月21日 |
|
||||
| 自动配置(简化配置) | 开发中 | 2020年4月10日 | |
|
||||
| 浏览器插件 | 暂未开始 | | |
|
||||
| 合集自动拆包辅种 | 暂未开始 | | |
|
||||
|
46
wiki/数据清理.md
46
wiki/数据清理.md
@@ -1,46 +0,0 @@
|
||||
## 404数据最后清理时间
|
||||
|标志 | 最后清理时间 | 状态 |
|
||||
| :-: | :-: | ---- |
|
||||
| 1ptba | 2020年1月19日12:00:00 | 已完成 |
|
||||
|52pt | 2020年1月19日12:00:00 | 已完成 |
|
||||
|beitai-备胎 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|brobits | 2020年1月19日12:00:00 | 已完成 |
|
||||
|btschool-学校 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|chdbits-彩虹岛 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|discfan-港知堂 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|dmhy-幼儿园 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|eastgame | 2020年1月19日12:00:00 | 已完成 |
|
||||
|hd4fans-兽 | | 已完成 |
|
||||
|hdarea-HDA | | |
|
||||
|hdbd-伊甸园 | | |
|
||||
|hdbug(hddisk) | 2020年1月19日12:00:00 | 已完成 |
|
||||
|hdchina-瓷器 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|hdcity-城市 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|hddolby-杜比 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|hdhome-家园 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|hdsky-天空 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|hdstreet | 2020年1月19日12:00:00 | 已完成 |
|
||||
|hdtime-时间 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|hdzone-HDZ | 2020年1月19日12:00:00 | 已完成 |
|
||||
|joyhd | 2020年1月19日12:00:00 | 已完成 |
|
||||
| keepfrds-朋友 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|leaguehd | 2020年1月19日12:00:00 | 已完成 |
|
||||
| m-team-馒头 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|moecat-萌猫 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|nanyangpt-南洋 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|nicept-老师 | | |
|
||||
|opencd-皇后 | | 已完成 |
|
||||
|oshen | 2020年1月19日12:00:00 | 已完成 |
|
||||
|ourbits-我堡 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|pterclub-猫站 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|pthome-铂金家 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|ptmsg | 2020年1月19日12:00:00 | 已完成 |
|
||||
|ptsbao-烧包 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|soulvoice-聆音 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|ssd-春天 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|tjupt-北洋 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|torrentccf-TCCF | 2020年1月19日12:00:00 | 已完成 |
|
||||
| ttg-听听歌 | 2020年1月19日12:00:00 | 已完成 |
|
||||
| upxin | 2020年1月19日12:00:00 | 已完成 |
|
||||
| yingk-映客 | 2020年1月19日12:00:00 | 已完成 |
|
||||
|
24
wiki/更新历史.md
24
wiki/更新历史.md
@@ -4,6 +4,30 @@
|
||||
|
||||
------
|
||||
|
||||
### 2020年7月3日
|
||||
|
||||
1. 优化windows的辅种批处理,采用环境变量调用
|
||||
2. 新增站点HDRoute、hdbd、haidan、HDfans
|
||||
3. 优化curl的连接参数
|
||||
4. 新增小钢炮专用的docker脚本
|
||||
5. 新增合作站点MoeCat
|
||||
6. 微信报表增加版本号提示
|
||||
7. qBittorrent下载器增加root_folder配置项:是否创建子文件夹
|
||||
|
||||
### 2020年3月22日
|
||||
|
||||
1. 转移种子,设置自动开始开关
|
||||
2. 添加git自动更新.cmd
|
||||
3. 优化做种客户端转移配置的提示
|
||||
4. 人性化加入vendor目录
|
||||
5. 修复因不支持站点缓存引起的错误提示
|
||||
6. 新增合作站点hddolby、hdhome、pthome
|
||||
7. 修复瓷器辅种乱码不美观的问题
|
||||
8. 简化docker编译文件
|
||||
9. 优化合作站点登录缓存,检索请求
|
||||
10. 优化输出提示,未填写passkey的站点只提示一次,后续自动跳过
|
||||
11. 增加通用备份脚本
|
||||
|
||||
### 2020年2月26日
|
||||
|
||||
1. 新增:葡萄pt
|
||||
|
@@ -1,10 +1,10 @@
|
||||
以下教程以windows为基础进行讲解,通用威联通、群晖、铁威马等Linux系统。
|
||||
|
||||
# 重要提示:请先完整阅读完再动手操作!请先完整阅读完再动手操作!
|
||||
# 重要提示:请先完整阅读完再动手操作!
|
||||
|
||||
## 第一步 下载压缩包
|
||||
从[码云仓库][1],下载最新源码,源码需安装依赖才可运行(必须用composer install安装依赖包),解压缩到D盘的根目录下。
|
||||
**特殊说明:如果不会用composer安装依赖,请去群内下载zip压缩包,或者[点此下载vendor.zip][2],解压到上述目录内。**
|
||||
从[码云仓库][1],下载最新源码,解压缩到D盘的根目录下。
|
||||
**特殊说明:新手第一次使用建议去群内下载zip压缩包。**
|
||||
|
||||
|
||||
## 第二步 复制一份配置文件
|
||||
@@ -15,21 +15,29 @@
|
||||
提醒:千万不要用windows记事本来编辑配置文件!!
|
||||
推荐编辑软件:`VS code`、`EditPlus`、`SublimeText`、`Notepad++`等(保存格式,选UTF8 无BOM);
|
||||
配置文件内容较多,新手往往很迷茫,不知道改哪里,在这里我重点强调3个步骤:
|
||||
`1.申请爱语飞飞token;2.编辑全局客户端; 3.编辑各站的密钥,即passkey。`
|
||||
`1.申请爱语飞飞token;2.编辑全局客户端; 3.编辑各站的密钥即passkey;4.配置合作站点的passkey,用户id`
|
||||
其他配置,如果不懂也没有关系;先保持默认,等脚本运行起来,再修改也不迟。另外,修改时一定要细心,仔细看教程。
|
||||
**下面开始详细步骤!!!!**
|
||||
|
||||
|
||||
----------
|
||||
|
||||
|
||||
### 申请爱语飞飞微信通知token,新用户访问:http://iyuu.cn 申请!
|
||||
1.点击`开始使用`,出现二维码,用`微信扫码`
|
||||
![微信通知1.png][3]
|
||||
![微信通知2.png][4]
|
||||
![微信通知3.png][5]
|
||||
![微信通知1.png][2]
|
||||
![微信通知2.png][3]
|
||||
![微信通知3.png][4]
|
||||
2.复制您的token令牌到`/config/config.php`文件内的`iyuu.cn`对应的配置字段,保存。如图:
|
||||
![微信通知4.png][6]
|
||||
![微信通知4.png][5]
|
||||
|
||||
|
||||
----------
|
||||
|
||||
|
||||
### 填写全局客户端
|
||||
打开`D:\IYUUAutoReseed\config\config.php`文件,如下图:
|
||||
![编辑配置1.png][7]
|
||||
![编辑配置1.png][6]
|
||||
上图红框内的是`transmission`的示例配置,绿框是`qBittorrent`的示例配置;
|
||||
IYUU自动辅种工具,目前支持这两种下载器,支持多盘位,辅种时全自动对应资源的下载目录。
|
||||
#### 1,编辑`transmission`下载器
|
||||
@@ -39,60 +47,84 @@ username是用户名、password是密码。(没有用户名和密码的都填
|
||||
|
||||
#### 2,编辑`qBittorrent`下载器
|
||||
方法与上一步相同,只需填写ip、端口、用户名、密码即可。如果您是windows下的qBittorrent,请打开`WEB用户界面`,设置如下图:
|
||||
![qb设置WEB用户界面.png][8]
|
||||
![qb设置WEB用户界面.png][7]
|
||||
|
||||
因为我两个下载器都在用,编辑好后,如图:
|
||||
![编辑配置2.png][9]
|
||||
![编辑配置2.png][8]
|
||||
|
||||
|
||||
----------
|
||||
|
||||
|
||||
### 填写各站秘钥passkey
|
||||
IYUU自动辅种:需要您配置各站的passkey(目前支持40多个站点的自动辅种,没有配置passkey的站点会自动跳过)。
|
||||
从各站点的控制面板,找到您的`密钥`复制粘贴过来即可。
|
||||
IYUU自动辅种:需要您配置各站的passkey(目前支持40多个站点的自动辅种,没有配置passkey的站点会自动跳过)。注:2019年12月28日补充:辅种hdcity、hdchina需要配置cookie。
|
||||
|
||||
从各站点的控制面板或对应地方,找到您的`密钥`复制粘贴过来即可。
|
||||
配置好后如图:
|
||||
![编辑配置3.png][10]
|
||||
![编辑配置3.png][9]
|
||||
|
||||
|
||||
----------
|
||||
|
||||
|
||||
## 第四步,重点讲解Ourbits站点的配置
|
||||
IYUU自动辅种工具、Ourbits双方达成合作,可以对使用接口的用户,实现认证。
|
||||
|
||||
### 设置Ourbits:
|
||||
![编辑配置4.png][11]
|
||||
## 第四步,合作站点的配置
|
||||
此处配置也可以参考这里https://www.iyuu.cn/archives/337/
|
||||
IYUU自动辅种工具与站点达成合作,可以对使用接口的用户,实现认证。以Ourbits为例进行讲解
|
||||
![编辑配置4.png][10]
|
||||
`passkey`,在你的控制面板 - 密钥
|
||||
`id`,为用户中心打开后,浏览器地址栏**http://xxxxx.xxx/userdetails.php?id=`46880`**等号=后面的几个数字,如图:
|
||||
![编辑配置6.png][12]
|
||||
![编辑配置6.png][11]
|
||||
|
||||
如果有多个合作站账号,请全部配置,如图:
|
||||
![合作站点ID.png][12]
|
||||
|
||||
到此,配置文件编辑完毕,请记得保存;如果提示保存格式,请保存为UTF8(无BOM)格式。
|
||||
|
||||
到此,配置文件编辑完毕,请记得保存。
|
||||
如果提示保存格式,请保存为UTF8(无BOM)格式。
|
||||
|
||||
----------
|
||||
|
||||
|
||||
## 群晖、铁威马、威联通等Linux的php环境
|
||||
**群晖、铁威马、威联通自带php运行环境,非常简单。**
|
||||
经过上面步骤,其实已经完成了配置,只需要把脚本复制到设备内,用php命令运行脚本即可。
|
||||
下面是各系统运行php的命令:
|
||||
群晖php:`php`
|
||||
威联通php: `/mnt/ext/opt/apache/bin/php`
|
||||
铁威马php:`php`
|
||||
|
||||
群晖php命令:`php`
|
||||
威联通php命令: `/mnt/ext/opt/apache/bin/php`
|
||||
铁威马php命令:`php`
|
||||
|
||||
----------
|
||||
|
||||
|
||||
**威联通补充几个命令,找到辅种脚本:**
|
||||
```sh
|
||||
#查看php版本
|
||||
/mnt/ext/opt/apache/bin/php -v
|
||||
#切换admin
|
||||
sudo -i
|
||||
#搜索iyuu.php或IYUUAutoReseed
|
||||
find / -name iyuu.php
|
||||
#根据上一行命令搜索结果,组成辅种命令:
|
||||
/mnt/ext/opt/apache/bin/php 找到的路径/iyuu.php
|
||||
```
|
||||
|
||||
----------
|
||||
|
||||
## Windows安装PHP运行环境
|
||||
也可以去官方下载【https://www.php.net/downloads】
|
||||
**特别提醒:官方下载的记得开启`curl、fileinfo、mbstring`,这3个扩展。**
|
||||
**特别提醒:官方下载的记得开启`curl、fileinfo、mbstring`,这3个扩展。**
|
||||
**特别提醒:官方下载的记得开启`curl、fileinfo、mbstring`,这3个扩展。**
|
||||
**特别提醒:官方下载的记得开启`curl、json、mbstring`,这3个扩展。**
|
||||
**特别提醒:官方下载的记得开启`curl、json、mbstring`,这3个扩展。**
|
||||
**特别提醒:官方下载的记得开启`curl、json、mbstring`,这3个扩展。**
|
||||
![php开启扩展.png][13]
|
||||
**特别提醒:官方下载的记得开启`curl、fileinfo、mbstring`,这3个扩展。**
|
||||
**特别提醒:官方下载的记得开启`curl、fileinfo、mbstring`,这3个扩展。**
|
||||
**特别提醒:官方下载的记得开启`curl、fileinfo、mbstring`,这3个扩展。**
|
||||
|
||||
|
||||
**另外我打包了一份【扩展已开启】,下载地址:**
|
||||
!!!
|
||||
<a href="http://dawei.hk:81/php-7.4.2-nts-Win32-vc15-x86.zip" target="_blank"><h3><code>http://dawei.hk:81/php-7.4.2-nts-Win32-vc15-x86.zip</code></h3></a>
|
||||
<a href="http://dawei.hk:81/php-7.4.2-nts-Win32-vc15-x64.zip" target="_blank"><h3><code>http://dawei.hk:81/php-7.4.2-nts-Win32-vc15-x64.zip</code></h3></a>
|
||||
<a href="http://www.dawei.hk:81/php-7.4.2-nts-Win32-vc15-x86.zip" target="_blank"><h3><code>http://www.dawei.hk:81/php-7.4.2-nts-Win32-vc15-x86.zip</code></h3></a>
|
||||
<a href="http://www.dawei.hk:81/php-7.4.2-nts-Win32-vc15-x64.zip" target="_blank"><h3><code>http://www.dawei.hk:81/php-7.4.2-nts-Win32-vc15-x64.zip</code></h3></a>
|
||||
!!!
|
||||
|
||||
|
||||
----------
|
||||
|
||||
|
||||
@@ -100,23 +132,31 @@ IYUU自动辅种工具、Ourbits双方达成合作,可以对使用接口的用
|
||||
链接:https://share.weiyun.com/57uYFrn 密码:gurkdc
|
||||
下载回来是一个ZIP压缩包,解压到`D:\IYUUAutoReseed\`目录内,文件结构如图:
|
||||
![编辑配置7.png][14]
|
||||
点击红框内`执行辅种`即可,也可以运行命令:`php iyuu.php`。
|
||||
重点:根据你下载的版本不同、路径不同,请把你解压的php环境的路径添加进系统的环境变量内。比如我下载的是`php-7.4.2-nts-Win32-vc15-x86.zip`解压到了D盘根目录下,可以这样添加:
|
||||
![请输入图片描述][15]
|
||||
|
||||
然后,点击红框内`执行辅种`即可,也可以运行命令:`php iyuu.php`。
|
||||
|
||||
> 提示:新手第一次请去群内下载打包好的Windows版本,双击运行即可。
|
||||
|
||||
|
||||
如果你前期严格按照配置一步步操作,这里会正常显示跑动的辅种列表。正常如图:
|
||||
![编辑配置8.png][15]
|
||||
![编辑配置8.png][16]
|
||||
|
||||
|
||||
[1]: https://gitee.com/ledc/IYUUAutoReseed
|
||||
[2]: https://www.iyuu.cn/usr/uploads/2020/02/3155906692.zip
|
||||
[3]: https://www.iyuu.cn/usr/uploads/2019/12/2331433923.png
|
||||
[4]: https://www.iyuu.cn/usr/uploads/2019/12/3324442680.png
|
||||
[5]: https://www.iyuu.cn/usr/uploads/2019/12/3181272964.png
|
||||
[6]: https://www.iyuu.cn/usr/uploads/2019/12/3669828008.png
|
||||
[7]: https://www.iyuu.cn/usr/uploads/2019/12/2720183833.png
|
||||
[8]: https://www.iyuu.cn/usr/uploads/2019/12/405587689.png
|
||||
[9]: https://www.iyuu.cn/usr/uploads/2019/12/441257656.png
|
||||
[10]: https://www.iyuu.cn/usr/uploads/2019/12/890327305.png
|
||||
[11]: https://www.iyuu.cn/usr/uploads/2019/12/3696916642.png
|
||||
[12]: https://www.iyuu.cn/usr/uploads/2019/12/1230288911.png
|
||||
[13]: https://www.iyuu.cn/usr/uploads/2019/12/3007415838.png
|
||||
[14]: https://www.iyuu.cn/usr/uploads/2019/12/3189986236.png
|
||||
[15]: https://www.iyuu.cn/usr/uploads/2019/12/2523845772.png
|
||||
[1]: https://gitee.com/ledc/IYUUAutoReseed
|
||||
[2]: https://www.iyuu.cn/usr/uploads/2019/12/2331433923.png
|
||||
[3]: https://www.iyuu.cn/usr/uploads/2019/12/3324442680.png
|
||||
[4]: https://www.iyuu.cn/usr/uploads/2019/12/3181272964.png
|
||||
[5]: https://www.iyuu.cn/usr/uploads/2019/12/3669828008.png
|
||||
[6]: https://www.iyuu.cn/usr/uploads/2019/12/2720183833.png
|
||||
[7]: https://www.iyuu.cn/usr/uploads/2019/12/405587689.png
|
||||
[8]: https://www.iyuu.cn/usr/uploads/2019/12/441257656.png
|
||||
[9]: https://www.iyuu.cn/usr/uploads/2019/12/890327305.png
|
||||
[10]: https://www.iyuu.cn/usr/uploads/2019/12/3696916642.png
|
||||
[11]: https://www.iyuu.cn/usr/uploads/2019/12/1230288911.png
|
||||
[12]: https://www.iyuu.cn/usr/uploads/2020/04/712430028.png
|
||||
[13]: https://www.iyuu.cn/usr/uploads/2019/12/3007415838.png
|
||||
[14]: https://www.iyuu.cn/usr/uploads/2019/12/3189986236.png
|
||||
[15]: https://www.iyuu.cn/usr/uploads/2020/03/686511859.png
|
||||
[16]: https://www.iyuu.cn/usr/uploads/2019/12/2523845772.png
|
Reference in New Issue
Block a user