Skip to content

Commit c686b99

Browse files
committed
updates for organization of RPMs in artifactory by release version
1 parent ea915f1 commit c686b99

File tree

1 file changed

+13
-6
lines changed

1 file changed

+13
-6
lines changed

Jenkinsfile.github

+13-6
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,12 @@ pipeline {
1111
}
1212

1313
environment {
14-
IS_STABLE = getBuildIsStable()
14+
IS_STABLE = getBuildIsStable(releaseBranchIsStable: true)
1515
BUILD_METADATA = getRpmRevision(isStable: env.IS_STABLE)
1616
GIT_REPO_NAME = getRepoName()
17-
}
18-
17+
RELEASE_BRANCH_VERSION = getReleaseBranchVersion()
18+
}
19+
1920
stages {
2021
stage("Prepare") {
2122
steps {
@@ -41,10 +42,16 @@ pipeline {
4142
stage('Publish') {
4243
steps {
4344
script {
44-
publishCsmRpms(component: env.GIT_REPO_NAME, pattern: "dist/rpmbuild/RPMS/noarch/*.rpm", arch: "noarch", isStable: env.IS_STABLE)
45-
publishCsmRpms(component: env.GIT_REPO_NAME, pattern: "dist/rpmbuild/SRPMS/*.rpm", arch: "src", isStable: env.IS_STABLE)
45+
if(env.RELEASE_BRANCH_VERSION){
46+
RELEASE_FOLDER = "/" + env.RELEASE_BRANCH_VERSION
47+
} else {
48+
RELEASE_FOLDER = ""
49+
}
50+
publishCsmRpms(component: env.GIT_REPO_NAME + RELEASE_FOLDER, pattern: "dist/rpmbuild/RPMS/noarch/*.rpm", arch: "noarch", isStable: env.IS_STABLE)
51+
publishCsmRpms(component: env.GIT_REPO_NAME + RELEASE_FOLDER, pattern: "dist/rpmbuild/SRPMS/*.rpm", arch: "src", isStable: env.IS_STABLE)
52+
}
4653
}
4754
}
4855
}
4956
}
50-
}
57+

0 commit comments

Comments
 (0)