Commit 67e29957 authored by YM-RD-AP01\ymadmin's avatar YM-RD-AP01\ymadmin

20140144: Job [Deploy_CRM_API_Prod] configuration updated

Change performed by ·¨¼y°ó
parent 352b96f5
...@@ -15,15 +15,15 @@ ...@@ -15,15 +15,15 @@
master master
release/1.15GA release/1.15GA
hotfix/1.15.1GA</description> hotfix/1.15.1GA</description>
<defaultValue>release/1.40GA</defaultValue> <defaultValue>master</defaultValue>
<trim>false</trim> <trim>false</trim>
</hudson.plugins.global__variable__string__parameter.GlobalVariableStringParameterDefinition> </hudson.plugins.global__variable__string__parameter.GlobalVariableStringParameterDefinition>
</parameterDefinitions> </parameterDefinitions>
</hudson.model.ParametersDefinitionProperty> </hudson.model.ParametersDefinitionProperty>
<jenkins.model.BuildDiscarderProperty> <jenkins.model.BuildDiscarderProperty>
<strategy class="hudson.tasks.LogRotator"> <strategy class="hudson.tasks.LogRotator">
<daysToKeep>1</daysToKeep> <daysToKeep>-1</daysToKeep>
<numToKeep>2</numToKeep> <numToKeep>5</numToKeep>
<artifactDaysToKeep>-1</artifactDaysToKeep> <artifactDaysToKeep>-1</artifactDaysToKeep>
<artifactNumToKeep>-1</artifactNumToKeep> <artifactNumToKeep>-1</artifactNumToKeep>
</strategy> </strategy>
...@@ -51,11 +51,7 @@ hotfix/1.15.1GA</description> ...@@ -51,11 +51,7 @@ hotfix/1.15.1GA</description>
<disabled>false</disabled> <disabled>false</disabled>
<blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding> <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
<blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding> <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
<triggers> <triggers/>
<hudson.triggers.TimerTrigger>
<spec>0 7,13,17 * * *</spec>
</hudson.triggers.TimerTrigger>
</triggers>
<concurrentBuild>false</concurrentBuild> <concurrentBuild>false</concurrentBuild>
<rootModule> <rootModule>
<groupId>org.ylhealth.ym.chmapi</groupId> <groupId>org.ylhealth.ym.chmapi</groupId>
...@@ -65,7 +61,7 @@ hotfix/1.15.1GA</description> ...@@ -65,7 +61,7 @@ hotfix/1.15.1GA</description>
<defaultGoals>spring-boot:run</defaultGoals> <defaultGoals>spring-boot:run</defaultGoals>
<aggregatorStyleBuild>true</aggregatorStyleBuild> <aggregatorStyleBuild>true</aggregatorStyleBuild>
<incrementalBuild>false</incrementalBuild> <incrementalBuild>false</incrementalBuild>
<ignoreUpstremChanges>false</ignoreUpstremChanges> <ignoreUpstremChanges>true</ignoreUpstremChanges>
<ignoreUnsuccessfulUpstreams>false</ignoreUnsuccessfulUpstreams> <ignoreUnsuccessfulUpstreams>false</ignoreUnsuccessfulUpstreams>
<archivingDisabled>true</archivingDisabled> <archivingDisabled>true</archivingDisabled>
<siteArchivingDisabled>false</siteArchivingDisabled> <siteArchivingDisabled>false</siteArchivingDisabled>
...@@ -80,7 +76,7 @@ hotfix/1.15.1GA</description> ...@@ -80,7 +76,7 @@ hotfix/1.15.1GA</description>
<globalSettings class="jenkins.mvn.DefaultGlobalSettingsProvider"/> <globalSettings class="jenkins.mvn.DefaultGlobalSettingsProvider"/>
<reporters> <reporters>
<hudson.maven.reporters.MavenMailer> <hudson.maven.reporters.MavenMailer>
<recipients>$RD_Group</recipients> <recipients>$RD_Group $QA_Group</recipients>
<dontNotifyEveryUnstableBuild>false</dontNotifyEveryUnstableBuild> <dontNotifyEveryUnstableBuild>false</dontNotifyEveryUnstableBuild>
<sendToIndividuals>false</sendToIndividuals> <sendToIndividuals>false</sendToIndividuals>
<perModuleEmail>true</perModuleEmail> <perModuleEmail>true</perModuleEmail>
...@@ -123,20 +119,29 @@ hotfix/1.15.1GA</description> ...@@ -123,20 +119,29 @@ hotfix/1.15.1GA</description>
<hudson.plugins.timestamper.TimestamperBuildWrapper plugin="timestamper@1.8.10"/> <hudson.plugins.timestamper.TimestamperBuildWrapper plugin="timestamper@1.8.10"/>
</buildWrappers> </buildWrappers>
<prebuilders> <prebuilders>
<hudson.tasks.Shell> <hudson.tasks.BatchFile>
<command>VAR=$(git rev-parse --short HEAD)_$(date +&quot;%Y%m%d_%H%M&quot;) <command>set path=%path%;&quot;C:\Program Files\Git\usr\bin&quot;;&#xd;
version=$(echo $GIT_BRANCH | cut -d&apos;/&apos; -f 3) &#xd;
# sed -i &quot;s/&lt;title.*/&lt;title ng-bind=&apos;page_title&apos;&gt;CRM v${version}_${VAR}&lt;\/title\/&gt;/&quot; src/main/resources/static/index.html REM 取得今天的年、月、日 (自動補零)&#xd;
</command> SETLOCAL EnableDelayedExpansion&#xd;
</hudson.tasks.Shell> &#xd;
for /f &quot;skip=1 tokens=1-6 delims= &quot; %%a in (&apos;wmic path Win32_LocalTime Get Day^,Hour^,Minute^,Month^,Second^,Year /Format:table&apos;) do (&#xd;
IF NOT &quot;%%~f&quot;==&quot;&quot; (&#xd;
set /a FormattedDate=10000 * %%f + 100 * %%d + %%a&#xd;
set FormattedDate=%%f!FormattedDate:~-4,2!!FormattedDate:~-2,2!_%%b:%%c&#xd;
)&#xd;
)&#xd;
for /f &quot;tokens=*&quot; %%i in (&apos;git rev-parse --short HEAD&apos;) do set VAR=%%i_%FormattedDate%&#xd;
for /F &quot;delims=/ tokens=3&quot; %%i in (&quot;%GIT_BRANCH%&quot;) do set version=%%i&#xd;
&#xd;
echo Version:%VAR%</command>
</hudson.tasks.BatchFile>
</prebuilders> </prebuilders>
<postbuilders> <postbuilders>
<hudson.tasks.Shell> <hudson.tasks.BatchFile>
<command>systemctl stop CRM_API <command>ssh -i F:/jenkins/id_rsa ymadmin@10.36.220.122 &quot;rm -f /opt/chm/chmapi-pack.zip&quot;&#xd;
rm -f /opt/chm/chmapi/lib/*.jar scp -i F:/jenkins/id_rsa target/chmapi-pack.zip ymadmin@10.36.220.122:/opt/chm/</command>
/usr/bin/unzip -j -o target/chmapi-pack.zip &quot;chmapi/lib/*&quot; -d /opt/chm/chmapi/lib </hudson.tasks.BatchFile>
systemctl start CRM_API</command>
</hudson.tasks.Shell>
</postbuilders> </postbuilders>
<runPostStepsIfResult> <runPostStepsIfResult>
<name>SUCCESS</name> <name>SUCCESS</name>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment