Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
jenkins
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Jira
Jira
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ym
jenkins
Commits
67e29957
Commit
67e29957
authored
Nov 22, 2018
by
YM-RD-AP01\ymadmin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
20140144: Job [Deploy_CRM_API_Prod] configuration updated
Change performed by ·¨¼y°ó
parent
352b96f5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
27 additions
and
22 deletions
+27
-22
jobs/Deploy_CRM_API_Prod/config.xml
jobs/Deploy_CRM_API_Prod/config.xml
+27
-22
No files found.
jobs/Deploy_CRM_API_Prod/config.xml
View file @
67e29957
...
...
@@ -15,15 +15,15 @@
master
release/1.15GA
hotfix/1.15.1GA
</description>
<defaultValue>
release/1.40GA
</defaultValue>
<defaultValue>
master
</defaultValue>
<trim>
false
</trim>
</hudson.plugins.global__variable__string__parameter.GlobalVariableStringParameterDefinition>
</parameterDefinitions>
</hudson.model.ParametersDefinitionProperty>
<jenkins.model.BuildDiscarderProperty>
<strategy
class=
"hudson.tasks.LogRotator"
>
<daysToKeep>
1
</daysToKeep>
<numToKeep>
2
</numToKeep>
<daysToKeep>
-
1
</daysToKeep>
<numToKeep>
5
</numToKeep>
<artifactDaysToKeep>
-1
</artifactDaysToKeep>
<artifactNumToKeep>
-1
</artifactNumToKeep>
</strategy>
...
...
@@ -51,11 +51,7 @@ hotfix/1.15.1GA</description>
<disabled>
false
</disabled>
<blockBuildWhenDownstreamBuilding>
false
</blockBuildWhenDownstreamBuilding>
<blockBuildWhenUpstreamBuilding>
false
</blockBuildWhenUpstreamBuilding>
<triggers>
<hudson.triggers.TimerTrigger>
<spec>
0 7,13,17 * * *
</spec>
</hudson.triggers.TimerTrigger>
</triggers>
<triggers/>
<concurrentBuild>
false
</concurrentBuild>
<rootModule>
<groupId>
org.ylhealth.ym.chmapi
</groupId>
...
...
@@ -65,7 +61,7 @@ hotfix/1.15.1GA</description>
<defaultGoals>
spring-boot:run
</defaultGoals>
<aggregatorStyleBuild>
true
</aggregatorStyleBuild>
<incrementalBuild>
false
</incrementalBuild>
<ignoreUpstremChanges>
fals
e
</ignoreUpstremChanges>
<ignoreUpstremChanges>
tru
e
</ignoreUpstremChanges>
<ignoreUnsuccessfulUpstreams>
false
</ignoreUnsuccessfulUpstreams>
<archivingDisabled>
true
</archivingDisabled>
<siteArchivingDisabled>
false
</siteArchivingDisabled>
...
...
@@ -80,7 +76,7 @@ hotfix/1.15.1GA</description>
<globalSettings
class=
"jenkins.mvn.DefaultGlobalSettingsProvider"
/>
<reporters>
<hudson.maven.reporters.MavenMailer>
<recipients>
$RD_Group
</recipients>
<recipients>
$RD_Group
$QA_Group
</recipients>
<dontNotifyEveryUnstableBuild>
false
</dontNotifyEveryUnstableBuild>
<sendToIndividuals>
false
</sendToIndividuals>
<perModuleEmail>
true
</perModuleEmail>
...
...
@@ -123,20 +119,29 @@ hotfix/1.15.1GA</description>
<hudson.plugins.timestamper.TimestamperBuildWrapper
plugin=
"timestamper@1.8.10"
/>
</buildWrappers>
<prebuilders>
<hudson.tasks.Shell>
<command>
VAR=$(git rev-parse --short HEAD)_$(date +
"
%Y%m%d_%H%M
"
)
version=$(echo $GIT_BRANCH | cut -d
'
/
'
-f 3)
# sed -i
"
s/
<
title.*/
<
title ng-bind=
'
page_title
'>
CRM v${version}_${VAR}
<
\/title\/
>
/
"
src/main/resources/static/index.html
</command>
</hudson.tasks.Shell>
<hudson.tasks.BatchFile>
<command>
set path=%path%;
"
C:\Program Files\Git\usr\bin
"
;


REM 取得今天的年、月、日 (自動補零)

SETLOCAL EnableDelayedExpansion


for /f
"
skip=1 tokens=1-6 delims=
"
%%a in (
'
wmic path Win32_LocalTime Get Day^,Hour^,Minute^,Month^,Second^,Year /Format:table
'
) do (

IF NOT
"
%%~f
"
==
""
(

set /a FormattedDate=10000 * %%f + 100 * %%d + %%a

set FormattedDate=%%f!FormattedDate:~-4,2!!FormattedDate:~-2,2!_%%b:%%c

)

)

for /f
"
tokens=*
"
%%i in (
'
git rev-parse --short HEAD
'
) do set VAR=%%i_%FormattedDate%

for /F
"
delims=/ tokens=3
"
%%i in (
"
%GIT_BRANCH%
"
) do set version=%%i


echo Version:%VAR%
</command>
</hudson.tasks.BatchFile>
</prebuilders>
<postbuilders>
<hudson.tasks.Shell>
<command>
systemctl stop CRM_API
rm -f /opt/chm/chmapi/lib/*.jar
/usr/bin/unzip -j -o target/chmapi-pack.zip
"
chmapi/lib/*
"
-d /opt/chm/chmapi/lib
systemctl start CRM_API
</command>
</hudson.tasks.Shell>
<hudson.tasks.BatchFile>
<command>
ssh -i F:/jenkins/id_rsa ymadmin@10.36.220.122
"
rm -f /opt/chm/chmapi-pack.zip
"
scp -i F:/jenkins/id_rsa target/chmapi-pack.zip ymadmin@10.36.220.122:/opt/chm/
</command>
</hudson.tasks.BatchFile>
</postbuilders>
<runPostStepsIfResult>
<name>
SUCCESS
</name>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment