chore: 删除废弃的server-deploy目录

脚本已统一迁移到项目根目录scripts/
This commit is contained in:
zhangjf 2026-02-22 15:09:36 +08:00
parent dfce5b0566
commit 072fe267bb
18 changed files with 18 additions and 333 deletions

View File

@ -1,2 +1,2 @@
#Sun Feb 22 13:58:28 CST 2026
central|https\://repo1.maven.org/maven2|null=1771739908393
#Sun Feb 22 14:41:27 CST 2026
central|https\://repo1.maven.org/maven2|null=1771742487357

View File

@ -1,2 +1,2 @@
#Sun Feb 22 13:58:28 CST 2026
central|https\://repo1.maven.org/maven2|null=1771739908396
#Sun Feb 22 14:41:27 CST 2026
central|https\://repo1.maven.org/maven2|null=1771742487369

View File

@ -1,2 +1,2 @@
#Sun Feb 22 13:58:28 CST 2026
central|https\://repo1.maven.org/maven2|null=1771739908400
#Sun Feb 22 14:41:27 CST 2026
central|https\://repo1.maven.org/maven2|null=1771742487399

View File

@ -1,2 +1,2 @@
#Sun Feb 22 13:58:28 CST 2026
central|https\://repo1.maven.org/maven2|null=1771739908400
#Sun Feb 22 14:41:27 CST 2026
central|https\://repo1.maven.org/maven2|null=1771742487396

View File

@ -1,2 +1,2 @@
#Sun Feb 22 13:58:28 CST 2026
central|https\://repo1.maven.org/maven2|null=1771739908398
#Sun Feb 22 14:41:27 CST 2026
central|https\://repo1.maven.org/maven2|null=1771742487373

View File

@ -1,2 +1,2 @@
#Sun Feb 22 13:58:28 CST 2026
central|https\://repo1.maven.org/maven2|null=1771739908394
#Sun Feb 22 14:41:27 CST 2026
central|https\://repo1.maven.org/maven2|null=1771742487363

View File

@ -1,2 +1,2 @@
#Sun Feb 22 13:58:28 CST 2026
central|https\://repo1.maven.org/maven2|null=1771739908401
#Sun Feb 22 14:41:27 CST 2026
central|https\://repo1.maven.org/maven2|null=1771742487400

View File

@ -1,2 +1,2 @@
#Sun Feb 22 13:58:28 CST 2026
central|https\://repo1.maven.org/maven2|null=1771739908397
#Sun Feb 22 14:41:27 CST 2026
central|https\://repo1.maven.org/maven2|null=1771742487372

View File

@ -1,2 +1,2 @@
#Sun Feb 22 13:58:28 CST 2026
central|https\://repo1.maven.org/maven2|null=1771739908398
#Sun Feb 22 14:41:27 CST 2026
central|https\://repo1.maven.org/maven2|null=1771742487376

View File

@ -1,63 +0,0 @@
<assembly xmlns="http://maven.apache.org/ASSEMBLY/2.2.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/ASSEMBLY/2.2.0 https://maven.apache.org/xsd/assembly-2.2.0.xsd">
<id>bin</id>
<formats>
<format>tar.gz</format>
</formats>
<includeBaseDirectory>true</includeBaseDirectory>
<fileSets>
<!-- bin目录 - 启动脚本 -->
<fileSet>
<directory>src/main/scripts</directory>
<outputDirectory>bin</outputDirectory>
<includes>
<include>*.sh</include>
</includes>
<fileMode>0755</fileMode>
<filtered>true</filtered>
</fileSet>
<!-- conf目录 - 配置文件 -->
<fileSet>
<directory>src/main/resources</directory>
<outputDirectory>conf</outputDirectory>
<includes>
<include>application.yml</include>
<include>application-*.yml</include>
<include>logback-spring.xml</include>
<include>bootstrap.yml</include>
<include>*.properties</include>
</includes>
<fileMode>0644</fileMode>
</fileSet>
<!-- lib目录 - 依赖JAR -->
<fileSet>
<directory>${project.build.directory}/dependency</directory>
<outputDirectory>lib</outputDirectory>
<includes>
<include>*.jar</include>
</includes>
<excludes>
<exclude>${project.artifactId}-${project.version}.jar</exclude>
</excludes>
<fileMode>0644</fileMode>
</fileSet>
</fileSets>
<files>
<!-- 主JAR包 -->
<file>
<source>${project.build.directory}/${project.artifactId}-${project.version}.jar</source>
<outputDirectory>lib</outputDirectory>
<destName>${project.artifactId}.jar</destName>
<fileMode>0644</fileMode>
</file>
</files>
</assembly>

View File

@ -1,10 +0,0 @@
#!/bin/bash
# 一键重启所有服务
DEPLOY_HOME="/opt/fundplatform/deploy"
${DEPLOY_HOME}/stop-all.sh
echo ""
echo "Waiting 10 seconds..."
sleep 10
${DEPLOY_HOME}/start-all.sh

View File

@ -1,9 +0,0 @@
#!/bin/bash
# 服务重启脚本
# 用法: ./restart.sh [服务名称]
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
${SCRIPT_DIR}/stop.sh
sleep 3
${SCRIPT_DIR}/start.sh

View File

@ -1,38 +0,0 @@
#!/bin/bash
# 一键启动所有服务
DEPLOY_HOME="/opt/fundplatform/deploy"
# 服务启动顺序
SERVICES=(
"fund-gateway"
"fund-sys"
"fund-cust"
"fund-proj"
"fund-req"
"fund-exp"
"fund-receipt"
"fund-report"
"fund-file"
)
echo "=========================================="
echo " Starting all services..."
echo "=========================================="
for service in "${SERVICES[@]}"; do
if [ -f "${DEPLOY_HOME}/${service}/bin/start.sh" ]; then
echo ""
echo "Starting ${service}..."
${DEPLOY_HOME}/${service}/bin/start.sh
sleep 5
else
echo "Warning: ${service}/bin/start.sh not found, skipping..."
fi
done
echo ""
echo "=========================================="
echo " All services started"
echo "=========================================="
${DEPLOY_HOME}/status.sh

View File

@ -1,41 +0,0 @@
#!/bin/bash
# 服务启动脚本
# 用法: ./start.sh [服务名称]
# 获取服务名称(从脚本所在目录推断)
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
APP_HOME=$(dirname "$SCRIPT_DIR")
APP_NAME=$(basename "$APP_HOME")
LOG_HOME="/datacfs/applogs/${APP_NAME}"
JAR_FILE="${APP_HOME}/lib/${APP_NAME}.jar"
PID_FILE="${APP_HOME}/${APP_NAME}.pid"
# JVM参数
JAVA_OPTS="-Xms256m -Xmx512m -XX:+UseG1GC -XX:MaxGCPauseMillis=200"
# 日志参数
LOG_OPTS="-Dlogging.file.path=${LOG_HOME} -DAPP_NAME=${APP_NAME}"
# 配置文件路径
CONFIG_OPTS="--spring.config.location=${APP_HOME}/conf/application.yml"
# 检查是否已运行
if [ -f "$PID_FILE" ]; then
PID=$(cat $PID_FILE)
if ps -p $PID > /dev/null 2>&1; then
echo "${APP_NAME} is already running (PID: $PID)"
exit 1
fi
fi
# 创建日志目录
mkdir -p ${LOG_HOME}
# 启动服务
echo "Starting ${APP_NAME}..."
nohup java $JAVA_OPTS $LOG_OPTS -jar $JAR_FILE $CONFIG_OPTS > /dev/null 2>&1 &
# 保存PID
echo $! > $PID_FILE
echo "${APP_NAME} started (PID: $(cat $PID_FILE))"

View File

@ -1,41 +0,0 @@
#!/bin/bash
# 查看所有服务状态
DEPLOY_HOME="/opt/fundplatform/deploy"
SERVICES=(
"fund-gateway:8000"
"fund-sys:8100"
"fund-cust:8200"
"fund-proj:8300"
"fund-req:8400"
"fund-exp:8500"
"fund-receipt:8600"
"fund-report:8700"
"fund-file:8800"
)
echo "=========================================="
echo " Service Status"
echo "=========================================="
printf "%-20s %-10s %-10s %s\n" "Service" "Port" "Status" "PID"
echo "------------------------------------------"
for item in "${SERVICES[@]}"; do
service="${item%%:*}"
port="${item##*:}"
pid_file="${DEPLOY_HOME}/${service}/${service}.pid"
if [ -f "$pid_file" ]; then
PID=$(cat $pid_file)
if ps -p $PID > /dev/null 2>&1; then
printf "%-20s %-10s \033[32m%-10s\033[0m %s\n" "$service" "$port" "RUNNING" "$PID"
else
printf "%-20s %-10s \033[31m%-10s\033[0m %s\n" "$service" "$port" "STOPPED" "-"
fi
else
printf "%-20s %-10s \033[31m%-10s\033[0m %s\n" "$service" "$port" "STOPPED" "-"
fi
done
echo "=========================================="

View File

@ -1,32 +0,0 @@
#!/bin/bash
# 查看服务状态
# 用法: ./status.sh [服务名称]
# 获取服务名称(从脚本所在目录推断)
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
APP_HOME=$(dirname "$SCRIPT_DIR")
APP_NAME=$(basename "$APP_HOME}")
PID_FILE="${APP_HOME}/${APP_NAME}.pid"
echo "=========================================="
echo " Service: ${APP_NAME}"
echo "=========================================="
if [ -f "$PID_FILE" ]; then
PID=$(cat $PID_FILE)
if ps -p $PID > /dev/null 2>&1; then
echo "Status: \033[32mRUNNING\033[0m"
echo "PID: ${PID}"
# 显示进程信息
ps -p $PID -o pid,ppid,%cpu,%mem,etime,cmd --no-headers 2>/dev/null
else
echo "Status: \033[31mSTOPPED\033[0m (stale PID file)"
rm -f $PID_FILE
fi
else
echo "Status: \033[31mSTOPPED\033[0m"
fi
echo "=========================================="

View File

@ -1,37 +0,0 @@
#!/bin/bash
# 一键停止所有服务
DEPLOY_HOME="/opt/fundplatform/deploy"
# 服务停止顺序(反向停止)
SERVICES=(
"fund-file"
"fund-report"
"fund-receipt"
"fund-exp"
"fund-req"
"fund-proj"
"fund-cust"
"fund-sys"
"fund-gateway"
)
echo "=========================================="
echo " Stopping all services..."
echo "=========================================="
for service in "${SERVICES[@]}"; do
if [ -f "${DEPLOY_HOME}/${service}/bin/stop.sh" ]; then
echo ""
echo "Stopping ${service}..."
${DEPLOY_HOME}/${service}/bin/stop.sh
sleep 2
else
echo "Warning: ${service}/bin/stop.sh not found, skipping..."
fi
done
echo ""
echo "=========================================="
echo " All services stopped"
echo "=========================================="

View File

@ -1,44 +0,0 @@
#!/bin/bash
# 服务停止脚本
# 用法: ./stop.sh [服务名称]
# 获取服务名称(从脚本所在目录推断)
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
APP_HOME=$(dirname "$SCRIPT_DIR")
APP_NAME=$(basename "$APP_HOME")
PID_FILE="${APP_HOME}/${APP_NAME}.pid"
# 检查是否运行
if [ ! -f "$PID_FILE" ]; then
echo "${APP_NAME} is not running"
exit 0
fi
PID=$(cat $PID_FILE)
if ! ps -p $PID > /dev/null 2>&1; then
echo "${APP_NAME} is not running"
rm -f $PID_FILE
exit 0
fi
# 停止服务
echo "Stopping ${APP_NAME} (PID: $PID)..."
kill $PID
# 等待停止
for i in {1..30}; do
if ! ps -p $PID > /dev/null 2>&1; then
break
fi
sleep 1
done
# 强制停止
if ps -p $PID > /dev/null 2>&1; then
echo "Force killing ${APP_NAME}..."
kill -9 $PID
fi
rm -f $PID_FILE
echo "${APP_NAME} stopped"