-
Notifications
You must be signed in to change notification settings - Fork 9
/
Jenkinsfile
25 lines (22 loc) · 944 Bytes
/
Jenkinsfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
node {
stage('Checkout') {
git url: 'https://github.com/xebialabs/rest-o-rant-api.git'
}
stage('Build') {
if (isUnix()) {
sh "./gradlew clean build"
} else {
bat("gradlew.bat clean build")
}
}
stage('Package') {
xldCreatePackage artifactsPath: 'build', manifestPath: 'deployit-manifest.xml', darPath: '$JOB_NAME-$BUILD_NUMBER.0.dar'
}
stage('Publish And Deploy') {
xldPublishPackage serverCredentials: 'Admin', darPath: '$JOB_NAME-$BUILD_NUMBER.0.dar'
xldDeploy serverCredentials: 'Admin', environmentId: 'Environments/Dev', packageId: 'Applications/rest-o-rant-api/$BUILD_NUMBER.0'
}
stage('Start XLR Release') {
xlrCreateRelease serverCredentials: 'Admin', template: 'Release rest-o-rant-api', version: 'Release for $BUILD_TAG', variables: [[propertyName: 'version', propertyValue: '$BUILD_NUMBER.0']], startRelease: true
}
}