更新 .gitea/workflows/dev.yml
Some checks failed
/ build-parent-pom (push) Successful in 1m55s
/ build-and-push-services (ruoyi-auth) (push) Failing after 26s
/ build-and-push-services (ruoyi-gateway) (push) Failing after 27s
/ build-and-push-services (ruoyi-modules/Property) (push) Failing after 26s
/ build-and-push-services (ruoyi-modules/Sis) (push) Failing after 27s
/ build-and-push-services (ruoyi-modules/ruoyi-gen) (push) Failing after 27s
/ build-and-push-services (ruoyi-modules/ruoyi-job) (push) Failing after 25s
/ build-and-push-services (ruoyi-modules/ruoyi-resource) (push) Failing after 25s
/ build-and-push-services (ruoyi-modules/ruoyi-system) (push) Failing after 25s
/ build-and-push-services (ruoyi-modules/ruoyi-workflow) (push) Failing after 26s
/ build-and-push-services (ruoyi-seata-server) (push) Failing after 17s
/ build-and-push-services (ruoyi-sentinel-dashboard) (push) Failing after 17s
/ build-and-push-services (ruoyi-snailjob-server) (push) Failing after 17s
/ build-and-push-services (ruoyi-visual/ruoyi-monitor) (push) Failing after 24s
/ build-and-push-services (ruoyi-visual/ruoyi-nacos) (push) Failing after 23s

This commit is contained in:
bichangxiong 2025-08-14 12:04:13 +08:00
parent 8c32e29571
commit f807f37395

View File

@ -80,50 +80,50 @@ jobs:
sleep 10
done
build-common-modules:
needs: build-parent-pom
runs-on: ubuntu
steps:
- name: 拉取代码仓库
uses: http://git.missmoc.top/mocheng/checkout@v4
# build-common-modules:
# needs: build-parent-pom
# runs-on: ubuntu
# steps:
# - name: 拉取代码仓库
# uses: http://git.missmoc.top/mocheng/checkout@v4
- name: 配置环境变量
run: |
export JAVA_HOME="/java17/java17"
export MAVEN_HOME="/maven/apache-maven-3.9.11"
echo "JAVA_HOME=$JAVA_HOME" >> $GITHUB_ENV
echo "$JAVA_HOME/bin" >> $GITHUB_PATH
echo "MAVEN_HOME=$MAVEN_HOME" >> $GITHUB_ENV
echo "$MAVEN_HOME/bin" >> $GITHUB_PATH
# - name: 配置环境变量
# run: |
# export JAVA_HOME="/java17/java17"
# export MAVEN_HOME="/maven/apache-maven-3.9.11"
# echo "JAVA_HOME=$JAVA_HOME" >> $GITHUB_ENV
# echo "$JAVA_HOME/bin" >> $GITHUB_PATH
# echo "MAVEN_HOME=$MAVEN_HOME" >> $GITHUB_ENV
# echo "$MAVEN_HOME/bin" >> $GITHUB_PATH
- name: 构建通用模块(仅本地使用,不上传)
run: |
COMMON_MODULES=(
"ruoyi-common"
"ruoyi-api"
"ruoyi-common-bom"
"ruoyi-common-alibaba-bom"
"ruoyi-api-bom"
)
# - name: 构建通用模块(仅本地使用,不上传)
# run: |
# COMMON_MODULES=(
# "ruoyi-common"
# "ruoyi-api"
# "ruoyi-common-bom"
# "ruoyi-common-alibaba-bom"
# "ruoyi-api-bom"
# )
for module in "${COMMON_MODULES[@]}"; do
MODULE_POM_ABSOLUTE_PATH="${GITHUB_WORKSPACE}/${module}/pom.xml"
if [ ! -f "$MODULE_POM_ABSOLUTE_PATH" ]; then
echo "警告:模块 $module 不存在,跳过"
continue
fi
# for module in "${COMMON_MODULES[@]}"; do
# MODULE_POM_ABSOLUTE_PATH="${GITHUB_WORKSPACE}/${module}/pom.xml"
# if [ ! -f "$MODULE_POM_ABSOLUTE_PATH" ]; then
# echo "警告:模块 $module 不存在,跳过"
# continue
# fi
retries=3
count=0
until "$MAVEN_HOME/bin/mvn" clean compile install -U -DskipTests -f "$MODULE_POM_ABSOLUTE_PATH"; do
count=$((count + 1))
if [ $count -ge $retries ]; then
echo "错误:模块 $module 构建失败"
exit 1
fi
sleep 10
done
done
# retries=3
# count=0
# until "$MAVEN_HOME/bin/mvn" clean compile install -U -DskipTests -f "$MODULE_POM_ABSOLUTE_PATH"; do
# count=$((count + 1))
# if [ $count -ge $retries ]; then
# echo "错误:模块 $module 构建失败"
# exit 1
# fi
# sleep 10
# done
# done
build-and-push-services:
needs: build-common-modules