Skip to content

Commit

Permalink
Remove debug and add publish of src artifacts.
Browse files Browse the repository at this point in the history
  • Loading branch information
steelhead31 committed Jan 17, 2025
1 parent 3f86eac commit 34fdfdd
Showing 1 changed file with 24 additions and 73 deletions.
97 changes: 24 additions & 73 deletions linux_new/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -30,62 +30,33 @@ def deb_distros = [
"bionic" // Ubuntu/18.04 (LTS)
]

// def rhel_distros = [
// 'rpm/centos/7',
// 'rpm/rocky/8',
// 'rpm/rhel/7',
// 'rpm/rhel/8',
// 'rpm/rhel/9',
// 'rpm/fedora/35',
// 'rpm/fedora/36',
// 'rpm/fedora/37',
// 'rpm/fedora/38',
// 'rpm/fedora/39',
// 'rpm/fedora/40',
// 'rpm/fedora/41',
// 'rpm/fedora/42',
// 'rpm/fedora/rawhide',
// 'rpm/oraclelinux/7',
// 'rpm/oraclelinux/8',
// 'rpm/amazonlinux/2'
// ]

// def suse_distros = [
// 'rpm/opensuse/15.3',
// 'rpm/opensuse/15.4',
// 'rpm/opensuse/15.5',
// 'rpm/sles/12',
// 'rpm/sles/15'
// ]

def rhel_distros = [
'sfr-rpm-test/centos/7',
'sfr-rpm-test/rocky/8',
'sfr-rpm-test/rhel/7',
'sfr-rpm-test/rhel/8',
'sfr-rpm-test/rhel/9',
'sfr-rpm-test/fedora/35',
'sfr-rpm-test/fedora/36',
'sfr-rpm-test/fedora/37',
'sfr-rpm-test/fedora/38',
'sfr-rpm-test/fedora/39',
'sfr-rpm-test/fedora/40',
'sfr-rpm-test/fedora/41',
'sfr-rpm-test/fedora/42',
'sfr-rpm-test/fedora/rawhide',
'sfr-rpm-test/oraclelinux/7',
'sfr-rpm-test/oraclelinux/8',
'sfr-rpm-test/amazonlinux/2'
]
'rpm/centos/7',
'rpm/rocky/8',
'rpm/rhel/7',
'rpm/rhel/8',
'rpm/rhel/9',
'rpm/fedora/35',
'rpm/fedora/36',
'rpm/fedora/37',
'rpm/fedora/38',
'rpm/fedora/39',
'rpm/fedora/40',
'rpm/fedora/41',
'rpm/fedora/42',
'rpm/fedora/rawhide',
'rpm/oraclelinux/7',
'rpm/oraclelinux/8',
'rpm/amazonlinux/2'
]

def suse_distros = [
'sfr-rpm-test/opensuse/15.3',
'sfr-rpm-test/opensuse/15.4',
'sfr-rpm-test/opensuse/15.5',
'sfr-rpm-test/sles/12',
'sfr-rpm-test/sles/15'
]

'rpm/opensuse/15.3',
'rpm/opensuse/15.4',
'rpm/opensuse/15.5',
'rpm/sles/12',
'rpm/sles/15'
]
/* End Of Distro Definitions*/

// Global Variables
Expand Down Expand Up @@ -312,7 +283,6 @@ pipeline {
script{
echo "Entering Stage : Process Parameters"
// Figure Out Which Dist This Run Is For
// ZZZZZZZZ ADD SOME BETTER HANDLING FOR MULTIPLES
if (params.ARTIFACTS_TO_COPY.contains('alpine-linux')) {
distro = "alpine-linux"
} else if (params.ARTIFACTS_TO_COPY.contains('linux')) {
Expand Down Expand Up @@ -687,18 +657,14 @@ stage('Generate Spec File') {
def genresult = sh(script: speccmd, returnStatus: true)
// End Of RHEL SUSE CODE
}

}

}

// Archive & store the generated files, for future reference

ArchiveFileName = "Package_Bld_Src_${distro}_${params.TAG}_${arch}_${env.BUILD_NUMBER}.tar.gz"
echo "ArchiveFileName = ${ArchiveFileName}"
sh "find ./linux_new -type f \\( -name '*.spec' -o -name 'control' -o -name 'changelog' -o -name 'rules' -o -name 'APKBUILD' \\) | tar -czf ./${ArchiveFileName} -T -"
sh "pwd"
sh "ls -ltr"

// Publish the tarball
archiveArtifacts artifacts: "${ArchiveFileName}", allowEmptyArchive: false
Expand Down Expand Up @@ -906,21 +872,6 @@ stage('Publish Packages') {
}
// Stage Definition - End
}
// Add Post Build Trigger To Run Publish_Linux_PkG_Src Job
// post {
// success {
// echo 'Build succeeded. Triggering downstream job...'
// echo "Release : ${params.TAG}"
// echo "FileName : ${ArchiveFileName}"
// echo "Dry Run : ${params.DRY_RUN}"

// build job: 'sfr-publish-linux-pck', parameters: [
// string(name: 'TAG', value: "${params.TAG}"),
// string(name: 'FILENAME', value: "${ArchiveFileName}"),
// booleanParam(name: 'DRY_RUN', value: params.DRY_RUN)
// ]
// }
// }
post {
success {
script {
Expand Down

0 comments on commit 34fdfdd

Please sign in to comment.