瀏覽代碼

v3.6.4 2025-04-02
update utool.sh

oubo 1 月之前
父節點
當前提交
8b05eef427
共有 1 個文件被更改,包括 6 次插入2 次删除
  1. 6 2
      bin/utool.sh

+ 6 - 2
bin/utool.sh

@@ -123,11 +123,16 @@ function pH() {
 }
 #pull license
 function pL() {
+  if [ -z "$DOMAIN_NAME" ]; then
+    echo -e "无法获取域名\r"
+    exit
+  fi
   licContent=$(curl -s -H "Accept:text/html" "${API_URL}/api/get-license" -X POST -d "{\"h\": \"$(hostname)\",\"d\":\"${DOMAIN_NAME}\"}")
   if [ -z "${licContent}" ];then
     echo -e "无法获取授权文件"
   fi
   echo "${licContent}" > "/app/license.txt"
+  echo -e "更新授权成功"
 }
 #pull code
 function pC() {
@@ -329,7 +334,7 @@ function rAP(){
 #crontab task
 function cT() {
 #每日3点检查硬盘使用率、证书有效期、增量备份数据库
-pU
+pDU
 renewSSL
 bD
 }
@@ -338,7 +343,6 @@ bD
 function eOD(){
   mariadb-dump -uroot -hmariadb --skip-ssl --no-create-info --ignore-table="$1".t_log_edit "$1" > $1.data.sql
 }
-
 if [ -n "$1" ];then
   "$1" "$2" "$3"
 else