bwcx_jzy 1 rok temu
rodzic
commit
8f3479d01c

+ 0 - 0
HEADER-LICENSE → HEADER.txt


+ 3 - 1
modules/server/src/main/java/org/dromara/jpom/controller/ToolsController.java

@@ -163,7 +163,9 @@ public class ToolsController {
         }
         if (!ipv4 && !ipv6) {
             String ipByHost = NetUtil.getIpByHost(host);
-            jsonObject.set("originalIP", ipByHost);
+            if (!StrUtil.equals(ipByHost, host)) {
+                jsonObject.set("originalIP", ipByHost);
+            }
             labels.put("DOMAIN");
         }
 

+ 1 - 1
modules/server/src/main/java/org/dromara/jpom/func/assets/controller/MachineSshController.java

@@ -209,7 +209,7 @@ public class MachineSshController extends BaseGroupNameController {
             JschUtil.close(session);
         } catch (Exception e) {
             log.warn("ssh连接失败", e);
-            return new JsonMessage<>(505, "ssh连接失败:" + e.getMessage());
+            return new JsonMessage<>(505, "ssh连接失败,请检查用户名、密码、host、端口等填写是否正确,超时时间是否合理:" + e.getMessage());
         }
         int i = add ? machineSshServer.insert(sshModel) : machineSshServer.updateById(sshModel);
         return JsonMessage.success("操作成功");

+ 0 - 1
modules/server/src/test/java/TestIp.java

@@ -7,7 +7,6 @@
  * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  * See the Mulan PSL v2 for more details.
  */
-
 import cn.hutool.core.net.Ipv4Util;
 import cn.hutool.core.net.NetUtil;
 import org.junit.Test;

+ 1 - 1
pom.xml

@@ -143,7 +143,7 @@
                     <licenseSets>
                         <licenseSet>
                             <!--HEADER文件-->
-                            <header>HEADER-LICENSE</header>
+                            <header>HEADER.txt</header>
                             <includes>
                                 <!--取消默认排除-->
                                 <include>**</include>

+ 10 - 0
web-vue/src/d.ts/auto-global-import.d.ts

@@ -1,3 +1,13 @@
+///
+/// Copyright (c) 2019 Of Him Code Technology Studio
+/// Jpom is licensed under Mulan PSL v2.
+/// You can use this software according to the terms and conditions of the Mulan PSL v2.
+/// You may obtain a copy of Mulan PSL v2 at:
+/// 			http://license.coscl.org.cn/MulanPSL2
+/// THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
+/// See the Mulan PSL v2 for more details.
+///
+
 /* eslint-disable */
 /* prettier-ignore */
 // @ts-nocheck

+ 10 - 0
web-vue/src/d.ts/auto-import.d.ts

@@ -1,3 +1,13 @@
+///
+/// Copyright (c) 2019 Of Him Code Technology Studio
+/// Jpom is licensed under Mulan PSL v2.
+/// You can use this software according to the terms and conditions of the Mulan PSL v2.
+/// You may obtain a copy of Mulan PSL v2 at:
+/// 			http://license.coscl.org.cn/MulanPSL2
+/// THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
+/// See the Mulan PSL v2 for more details.
+///
+
 /* eslint-disable */
 /* prettier-ignore */
 // @ts-nocheck

+ 10 - 0
web-vue/src/d.ts/components.d.ts

@@ -1,3 +1,13 @@
+///
+/// Copyright (c) 2019 Of Him Code Technology Studio
+/// Jpom is licensed under Mulan PSL v2.
+/// You can use this software according to the terms and conditions of the Mulan PSL v2.
+/// You may obtain a copy of Mulan PSL v2 at:
+/// 			http://license.coscl.org.cn/MulanPSL2
+/// THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
+/// See the Mulan PSL v2 for more details.
+///
+
 /* eslint-disable */
 /* prettier-ignore */
 // @ts-nocheck

+ 17 - 1
web-vue/src/pages/tools/network.vue

@@ -1,7 +1,20 @@
 <template>
   <div>
     <a-collapse v-model:activeKey="activeKey">
-      <a-collapse-panel key="1" header="服务端机器网络">
+      <a-collapse-panel key="1">
+        <template #header>
+          服务端机器网络
+          <a-tooltip>
+            <template #title>
+              <ul>
+                <li>A类 10.0.0.0-10.255.255.255</li>
+                <li>B类 172.16.0.0-172.31.255.255</li>
+                <li>C类 192.168.0.0-192.168.255.255</li>
+              </ul>
+            </template>
+            <QuestionCircleOutlined />
+          </a-tooltip>
+        </template>
         <a-space direction="vertical" style="width: 100%">
           <template v-for="item in ipListArray">
             <a-list size="small" bordered :data-source="item.ips">
@@ -31,6 +44,9 @@
           :wrapper-col="{ span: 18 }"
           @finish="onPingSubmit"
         >
+          <a-form-item label="提示" name="">
+            <a-alert message="不等同于 PING 测试,此处测试成功表示网络一定互通,此处测试失败网络不一定不通畅" banner />
+          </a-form-item>
           <a-form-item label="HOST" name="host">
             <a-input
               v-model:value="pingData.host"