Skip to content

Commit

Permalink
remove plan update
Browse files Browse the repository at this point in the history
  • Loading branch information
Jrohy committed Mar 19, 2020
1 parent 76101e6 commit 4853431
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 39 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ V2ray多用户管理脚本,向导式管理[新增|删除|修改]传输协议
- [x] **多用户, 多端口管理**, 混合传输协议管理不再是梦
- [x] 首次安装时产生随机端口,默认配置mkcp + 随机一种 (srtp | wechat-video | utp | dtls | wireguard) header伪装;
 安装完成显示配置信息;
- [x] 每天**北京时间**早上3点自动升级重启v2ray核心,降低v2ray因内存小被kill几率。可关闭开启此功能。
- [x] 查看配置信息显示vmess字符串(v2rayN的分享链接格式)
- [x] 生成**Telegram**的socks5/MTProto分享链接, 支持socks5 + tls组合
- [x] 支持http/2, 随机生成伪装h2 path
- [x] 开启关闭tcpFastOpen
- [x] 直接开启[CDN](https://github.com/Jrohy/multi-v2ray/wiki/CloudFlare-cdn%E4%BB%A3%E7%90%86v2ray%E6%B5%81%E9%87%8F)
- [x] 开启关闭动态端口
- [x] 定时更新v2ray(需手动开启)
- [x] 支持新版v2ray配置文件格式(v4.1+)
- [x] 支持范围端口修改
- [x] 支持程序和**命令行参数**管理控制
Expand Down
38 changes: 0 additions & 38 deletions v2ray.sh
Original file line number Diff line number Diff line change
Expand Up @@ -166,41 +166,6 @@ installDependent(){
bash <(curl -sL https://python3.netlify.com/install.sh)
}

#设置定时升级任务
planUpdate(){
[[ $NETWORK == 1 ]] && return

if [[ $CHINESE == 1 ]];then
#计算北京时间早上3点时VPS的实际时间
ORIGIN_TIME_ZONE=$(date -R|awk '{printf"%d",$6}')
LOCAL_TIME_ZONE=${ORIGIN_TIME_ZONE%00}
BEIJING_ZONE=8
DIFF_ZONE=$[$BEIJING_ZONE-$LOCAL_TIME_ZONE]
LOCAL_TIME=$[$BEIJING_UPDATE_TIME-$DIFF_ZONE]
if [ $LOCAL_TIME -lt 0 ];then
LOCAL_TIME=$[24+$LOCAL_TIME]
elif [ $LOCAL_TIME -ge 24 ];then
LOCAL_TIME=$[$LOCAL_TIME-24]
fi
colorEcho ${BLUE} "beijing time ${BEIJING_UPDATE_TIME}, VPS time: ${LOCAL_TIME}\n"
else
LOCAL_TIME=3
fi
OLD_CRONTAB=$(crontab -l)
echo "SHELL=/bin/bash" >> crontab.txt
echo "${OLD_CRONTAB}" >> crontab.txt
echo "0 ${LOCAL_TIME} * * * bash <(curl -L -s https://install.direct/go.sh) | tee -a /root/v2rayUpdate.log && v2ray-util restart" >> crontab.txt
crontab crontab.txt
sleep 1
if [[ ${PACKAGE_MANAGER} == 'dnf' || ${PACKAGE_MANAGER} == 'yum' ]];then
systemctl restart crond
else
systemctl restart cron
fi
rm -f crontab.txt
colorEcho ${GREEN} "success open schedule update task: beijing time ${BEIJING_UPDATE_TIME}\n"
}

updateProject() {
[[ ! $(type pip 2>/dev/null) ]] && colorEcho $RED "pip no install!" && exit 1

Expand Down Expand Up @@ -301,9 +266,6 @@ main() {

timeSync

#设置定时任务
[[ -z $(crontab -l|grep v2ray) ]] && planUpdate

updateProject

profileInit
Expand Down

0 comments on commit 4853431

Please sign in to comment.