mirror of https://github.com/mack-a/v2ray-agent
fix(脚本): 修改dns安装通配符证书后无法手动更新证书问题
parent
c452e5ded7
commit
0f66d3f473
|
@ -218,6 +218,9 @@ initVar() {
|
||||||
|
|
||||||
# 读取tls证书详情
|
# 读取tls证书详情
|
||||||
readAcmeTLS() {
|
readAcmeTLS() {
|
||||||
|
if [[ -n "${currentHost}" ]]; then
|
||||||
|
dnsTLSDomain=$(echo "${currentHost}" | awk -F "[.]" '{print $(NF-1)"."$NF}')
|
||||||
|
fi
|
||||||
if [[ -d "$HOME/.acme.sh/*.${dnsTLSDomain}_ecc" && -f "$HOME/.acme.sh/*.${dnsTLSDomain}_ecc/*.${dnsTLSDomain}.key" && -f "$HOME/.acme.sh/*.${dnsTLSDomain}_ecc/*.${dnsTLSDomain}.cer" ]]; then
|
if [[ -d "$HOME/.acme.sh/*.${dnsTLSDomain}_ecc" && -f "$HOME/.acme.sh/*.${dnsTLSDomain}_ecc/*.${dnsTLSDomain}.key" && -f "$HOME/.acme.sh/*.${dnsTLSDomain}_ecc/*.${dnsTLSDomain}.cer" ]]; then
|
||||||
installDNSACMEStatus=true
|
installDNSACMEStatus=true
|
||||||
fi
|
fi
|
||||||
|
@ -1427,9 +1430,11 @@ installCronTLS() {
|
||||||
|
|
||||||
# 更新证书
|
# 更新证书
|
||||||
renewalTLS() {
|
renewalTLS() {
|
||||||
|
|
||||||
if [[ -n $1 ]]; then
|
if [[ -n $1 ]]; then
|
||||||
echoContent skyBlue "\n进度 $1/1 : 更新证书"
|
echoContent skyBlue "\n进度 $1/1 : 更新证书"
|
||||||
fi
|
fi
|
||||||
|
readAcmeTLS
|
||||||
local domain=${currentHost}
|
local domain=${currentHost}
|
||||||
if [[ -z "${currentHost}" && -n "${tlsDomain}" ]]; then
|
if [[ -z "${currentHost}" && -n "${tlsDomain}" ]]; then
|
||||||
domain=${tlsDomain}
|
domain=${tlsDomain}
|
||||||
|
@ -1440,7 +1445,6 @@ renewalTLS() {
|
||||||
sslRenewalDays=180
|
sslRenewalDays=180
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -d "$HOME/.acme.sh/${domain}_ecc" && -f "$HOME/.acme.sh/${domain}_ecc/${domain}.key" && -f "$HOME/.acme.sh/${domain}_ecc/${domain}.cer" ]] || [[ "${installDNSACMEStatus}" == "true" ]]; then
|
if [[ -d "$HOME/.acme.sh/${domain}_ecc" && -f "$HOME/.acme.sh/${domain}_ecc/${domain}.key" && -f "$HOME/.acme.sh/${domain}_ecc/${domain}.cer" ]] || [[ "${installDNSACMEStatus}" == "true" ]]; then
|
||||||
modifyTime=
|
modifyTime=
|
||||||
|
|
||||||
|
@ -4999,7 +5003,7 @@ menu() {
|
||||||
cd "$HOME" || exit
|
cd "$HOME" || exit
|
||||||
echoContent red "\n=============================================================="
|
echoContent red "\n=============================================================="
|
||||||
echoContent green "作者:mack-a"
|
echoContent green "作者:mack-a"
|
||||||
echoContent green "当前版本:v2.6.4"
|
echoContent green "当前版本:v2.6.5"
|
||||||
echoContent green "Github:https://github.com/mack-a/v2ray-agent"
|
echoContent green "Github:https://github.com/mack-a/v2ray-agent"
|
||||||
echoContent green "描述:八合一共存脚本\c"
|
echoContent green "描述:八合一共存脚本\c"
|
||||||
showInstallStatus
|
showInstallStatus
|
||||||
|
|
Loading…
Reference in New Issue