LingxinMeng vor 7 Monaten
Ursprung
Commit
7855f59455

+ 13 - 0
simulation-gateway/src/main/resources/bootstrap-center.yaml

@@ -0,0 +1,13 @@
+# 国汽私有云
+spring:
+  cloud:
+    nacos:
+      discovery:
+        server-addr: 192.168.11.221:8848
+        namespace: 3698bfc2-a612-487a-b2a2-aaad16cd9d9d
+        group: private
+      config:
+        server-addr: 192.168.11.221:8848
+        namespace: 3698bfc2-a612-487a-b2a2-aaad16cd9d9d
+        file-extension: yaml
+        group: private

+ 1 - 0
simulation-gateway/start-center.sh

@@ -0,0 +1 @@
+nohup java -jar -Xms2048m -Xmx2048m simulation-oauth-server-1.0.jar --spring.profiles.active=center &

+ 12 - 0
simulation-gateway/stop.sh

@@ -0,0 +1,12 @@
+#!/bin/bash
+
+# 获取运行 simulation-oauth-server-1.0.jar 的 Java 进程的 PID
+PID=$(ps -ef | grep simulation-oauth-server-1.0.jar | grep java | awk '{ print $2 }')
+
+# 检查是否找到了 PID
+if [ -z "$PID" ]; then
+    echo "Application is already stopped or not found"
+else
+    echo "Killing process with PID: $PID"
+    kill $PID
+fi