Installed Endevor Zowe Cli, looking for sample build script to get an idea on how to enable Endevor build automation.
Release : 18.1
Component : CA Endevor Software Change Manager
CA Brightside 3.0
Sample Jenkins groovy script using Endevor Zowe Cli:
node {
stage('Code Scan') {
echo 'Scanning updated programs'
sh 'zowe endevor retrieve element "*" --env DEV --sn 1 --sys FINANCE --sub ACCTREC --typ COBPGM --to-dir "C:\\codescan" -i ENDEVOR --nsign'
sh '"C:\\Program Files (x86)\\Jenkins\\tools\\hudson.
}
stage('Build') {
echo 'Building progam updates'
sh 'zowe endevor generate element "*" --env QA --sn 1 --sys FINANCE --sub ACCTREC --typ COBPGM -i ENDEVOR --where-ccid-current ${CCID} --ccid ${CCID} --comment Jenkins_Build'
sh 'zowe endevor generate element "*" --env QA --sn 1 --sys FINANCE --sub ACCTREC --typ LNK -i ENDEVOR --where-ccid-current ${CCID} --ccid ${CCID} --comment Jenkins_Build'
}
stage('Tests') {
echo 'Updating test region'
sh 'zowe jobs submit data-set "MYHLQ.APP.JCL(SLICKDPL)" --wfo --vasc'
echo 'Executing CA Verify tests'
sh 'zowe jobs submit data-set "MYHLQ.APP.JCL(TEST)" --wfo --vasc'
}
stage('Package') {
echo 'Packaging code for promotion'
sh 'zowe endevor create package ${PKGNAME} -d "Package for CCID ${CCID}" -i ENDEVOR --novalidate-scl --ft "SET OPTIONS CCID ${CCID} COMMENT ${CCID} . "'
sh 'zowe endevor list elements --env QA --sn 1 --sys FINANCE --sub FINANCE --typ "*" -i ENDEVOR --where-ccid-current ${CCID} --to-package ${PKGNAME} --scl-action MOVE'
sh 'zowe endevor cast package ${PKGNAME} -i ENDEVOR'
}
stage('Promote') {
echo 'Promoting code'
sh 'zowe endevor execute package ${PKGNAME} -i ENDEVOR'
}
}