mirror of
https://github.com/xcp-ng/xenadmin.git
synced 2024-11-25 14:27:26 +01:00
Merge pull request #1412 from kc284/master
Moved checking out of branding specifics to the Jenkinsfile. Removed …
This commit is contained in:
commit
8d4913aa0d
26
Jenkinsfile
vendored
26
Jenkinsfile
vendored
@ -153,6 +153,19 @@ node("${params.BUILD_ON_NODE}") {
|
|||||||
rmdir /s /q "${env.WORKSPACE}\\xenadmin.git\\Branding"
|
rmdir /s /q "${env.WORKSPACE}\\xenadmin.git\\Branding"
|
||||||
xcopy /e /y "${env.WORKSPACE}\\xenadmin-branding.git\\${XC_BRANDING}\\*" "${env.WORKSPACE}\\xenadmin.git\\Branding\\"
|
xcopy /e /y "${env.WORKSPACE}\\xenadmin-branding.git\\${XC_BRANDING}\\*" "${env.WORKSPACE}\\xenadmin.git\\Branding\\"
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
println "Checking out branding specifics"
|
||||||
|
GString BRANDING_REMOTE = "${env.CODE_ENDPOINT}/xs/${XC_BRANDING}-branding.git"
|
||||||
|
|
||||||
|
def branchExistsOnBranding = bat(
|
||||||
|
returnStatus: true,
|
||||||
|
script: """git ls-remote --heads ${BRANDING_REMOTE} | grep ${params.XC_BRANCH}"""
|
||||||
|
)
|
||||||
|
String branchToCloneB = (branchExistsOnBranding == 0) ? params.XC_BRANCH : 'master'
|
||||||
|
|
||||||
|
bat """
|
||||||
|
git clone -b ${branchToCloneB} ${BRANDING_REMOTE} ${env.WORKSPACE}\\${XC_BRANDING}-branding.git
|
||||||
|
"""
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -216,6 +229,17 @@ node("${params.BUILD_ON_NODE}") {
|
|||||||
).trim()
|
).trim()
|
||||||
|
|
||||||
file << "xenadmin-branding xenadmin-branding.git ${XENADMIN_BRANDING_TIP}\n"
|
file << "xenadmin-branding xenadmin-branding.git ${XENADMIN_BRANDING_TIP}\n"
|
||||||
|
|
||||||
|
def XC_BRANDING_TIP = bat(
|
||||||
|
returnStdout: true,
|
||||||
|
script: """
|
||||||
|
@echo off
|
||||||
|
cd ${env.WORKSPACE}\\${XC_BRANDING}-branding.git
|
||||||
|
git rev-parse HEAD
|
||||||
|
"""
|
||||||
|
).trim()
|
||||||
|
|
||||||
|
file << "${XC_BRANDING}-branding ${XC_BRANDING}-branding.git ${XC_BRANDING_TIP}\n"
|
||||||
}
|
}
|
||||||
|
|
||||||
//for the time being we download a fixed version of the ovf fixup iso, hence put this in the manifest
|
//for the time being we download a fixed version of the ovf fixup iso, hence put this in the manifest
|
||||||
@ -253,7 +277,7 @@ node("${params.BUILD_ON_NODE}") {
|
|||||||
println "Testing package-and-sign script"
|
println "Testing package-and-sign script"
|
||||||
bat """
|
bat """
|
||||||
cd ${env.WORKSPACE}
|
cd ${env.WORKSPACE}
|
||||||
mkdir -p TestXenAdminUnsigned
|
mkdir TestXenAdminUnsigned
|
||||||
unzip -q -o output\\XenAdminUnsigned.zip -d TestXenAdminUnsigned
|
unzip -q -o output\\XenAdminUnsigned.zip -d TestXenAdminUnsigned
|
||||||
sh "TestXenAdminUnsigned/XenAdminUnsigned/mk/package-and-sign.sh"
|
sh "TestXenAdminUnsigned/XenAdminUnsigned/mk/package-and-sign.sh"
|
||||||
"""
|
"""
|
||||||
|
Loading…
Reference in New Issue
Block a user