summaryrefslogtreecommitdiffstats
path: root/jjb/global/releng-macros.yml
AgeCommit message (Collapse)AuthorFilesLines
2018-05-16Rename files under jjb from 'yml' to 'yaml'Trevor Bramwell1-1006/+0
global-jjb only supports the .yaml file ending for jjb jobs. Instead of waiting for a release we're going to rename the files. Change-Id: Icf3339eacd2320c583333e02250998cf6b1881f7 Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2018-05-16Clone Releng with submodules to include jjbAric Gardner1-0/+11
Needed for JJB verify and Merge to work. These jobs are going away, but first we need to get a verified +1 from jenkins Also remove releng-comment-jjb its unused Change-Id: Ice2ad625f87f1d9c841979ede4bb1943110691c8 Signed-off-by: Aric Gardner <agardner@linuxfoundation.org>
2018-05-14Disable git tagging during Jenkins git cloneTrevor Bramwell1-0/+4
Even with per-build-tag set to false, JJB 1.6.2 does not seem to remove 'Create tag for each build' from the git-scm settings. Though the option is deprecated it is still supported, so setting both of these should disable tagging when Jenkins clones a git repo. Change-Id: I5977149ad581df67d938ce2b46794d47c5e06fe3 Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2018-04-25Merge "Set Git SCM Defaults prior to JJB 1.6.2 upgrade"Aric Gardner1-0/+6
2018-04-24Set Git SCM Defaults prior to JJB 1.6.2 upgradeTrevor Bramwell1-0/+6
Though these defaults match what Jenkins defaults to, we don't want to get any surprises. Change-Id: Ia1f49a30f8f14992c548d2cf71c64a9c7a2c91dd Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2018-04-20Cleanup Archived projectsagardner1-40/+0
Removing archived projects from jjb These project dont need any jobs associated with them escalator fastpathmetrics inspector lsoapi movie multisite octopus openretriever prediction Change-Id: Ibbe49e54ed326f502157c7892022b7a62173b72d Signed-off-by: agardner <agardner@linuxfoundation.org>
2018-04-11Move DEPLOY_SCENARIO out of testapi-parametersTrevor Bramwell1-4/+28
These have been moved back into installer-params.yml and added to the daisy jobs where 'testapi-parameters' is being used. Including this in the list of parameters would cause duplication as most installers already include 'DEPLOY_SCENARIO' as a parameter. The 'DEPLOY_SCENARIO' parameter is also sometimes defined through a macro, which could cause second declaration of DEPLOY_SCENARIO (defaulting to 'os-nosdn-nofeature-ha') to always be used. Documentation has been added to the parameter to explain the related macros and how they should be used. Change-Id: I9aef031dbcf523ae2db15695ce294bd85025530d Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2018-03-12Define parameters for triggering jobsJulien1-2/+22
In https://wiki.jenkins.io/display/JENKINS/Plugins+affected+by+fix+for+SECURITY-170, it indicates that: only build parameters that have been explicitly defined in a job's configuration will be available by default at build time. Any other arbitrary parameters added to a build by plugins will not be available by default. It has been tested in sandbox.opnfv.org that only defined parameters can be passed to the triggered jobs. For parameters required by TESTAPI are common to all the projectes, including installers, Functest, and Yardstick, it is convenient to define a common macro and used by others. Change-Id: Iac1da85445e1b5d75109ccd64b174f35151b9969 Signed-off-by: Julien <zhang.jun3g@zte.com.cn>
2018-03-07Update return value from postbuildscriptJulien1-2/+4
PostBuildScript plugin's result affects Jenkins pipeline, so we should return the original job running status in the postbuildscript in the end Update macros: 1. from $POD_NAME to $NODE_NAME 2. from $SCENARIO to $DEPLOY_SCENARIO 2. {installer} to $INSTALLER_TYPE for {installer} is not existed in trigger job 3. add parameters definition for they can not be used in trigger jobs by predefined-parameters 4. missing TIMESTAMP_END Change-Id: I354be3d5ad02e53bb988995adc09b59e92a1640a Signed-off-by: Julien <zhang.jun3g@zte.com.cn>
2018-03-07Update include-raw tagJulien1-2/+2
replace `include-raw-escape` with `include-raw` for no jjb macros in the bash file. Change-Id: I6125779f23a5aafd7fed0f5017c4280394624bcd Signed-off-by: Julien <zhang.jun3g@zte.com.cn>
2018-03-01Report the result to TestAPIJulien1-1/+5
Report the provision result to TestAPI. Change-Id: I05a3a870125c2b1e74b98da043b53684ea334683 Signed-off-by: Julien <zhang.jun3g@zte.com.cn>
2018-02-24Merge "Update the postscriptbuild usage"Serena Feng1-0/+1
2018-02-22Merge "Jenkins not reporting lint results to gerrit"Aric Gardner1-1/+3
2018-02-22Jenkins not reporting lint results to gerritagardner1-1/+3
I set -x in a test and then it did report. not sure what's going on here, I thought this was fixed. May as well cat the violation log as we debug Change-Id: I142fb3855ebc000ee90aa24e0ecb336bb9b313df Signed-off-by: agardner <agardner@linuxfoundation.org>
2018-02-21Fix SFC Email PTL MacroTrevor Bramwell1-1/+1
Includes the name of the PTL but should be just the email. Change-Id: If6ef3b7c15defd44c6f86a24d6250840c37dd24b Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2018-02-12Update Dovetail PTL Email MacroTrevor Bramwell1-1/+1
Let the 'email-dovetail-ptl' macro reflect that Georg Kunz is the new PTL of the dovetail project. Change-Id: I3b3bd53a7c7f146105a719727fd627bf15054aca Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2018-02-12Update Pharos PTL in Email PTL MacroTrevor Bramwell1-1/+1
Julien has recently been promoted to PTL of the Pharos project and the macro for emailing the Pharos PTL should reflect this change. Change-Id: Id3f025cd87284d480da892fc999d7379af50ac95 Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2018-02-07fix sed command in macroswutianwei1-2/+2
The char "/" was included in $msg. It will have issue "sed: -e expression #1, char 7: unknown option to `s'" We can substitute '/' with '#' in sed command to solve this issue Signed-off-by: wutianwei <wutianwei1@huawei.com> Change-Id: I1308e9b1b2111f0033df119e4465df4dda27eac0
2018-02-05Update the postscriptbuild usageJulien1-1/+2
when we want to trigger the scipt only when previous builders fail, we should also set the other macro 'script-only-if-succeeded' to false, the default value is true. script-only-if-succeeded: false script-only-if-failed: true Change-Id: Ifdca24ea8d076dd4e16ef466705e0167b97cf1df Signed-off-by: Julien <zhang.jun3g@zte.com.cn>
2018-02-02Set the lint job shell to /bin/bashTrevor Bramwell1-0/+5
The default builder in Jenkins is '/bin/sh -ex'. Because of this lint jobs are failing that we assume won't as everywhere else we've used /bin/bash and explitily set options when needed. Explicitly setting these jobs to use /bin/bash should keep Jenkins from failing builds without reporting the lint results. Change-Id: Ibe6cad979d6dcf30e7991873c9ac446ae3bf3a8b Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2018-01-26Set lint jobs to run concurrentagardner1-1/+1
Liniting is broken, last fix forgot to run linting concurrent FATAL: The project is configured to NOT run builds concurrent, but the node parameter [SLAVE_NAME] is configured to trigger new builds concurrent! Change-Id: I1eb4bf7279c7af4e01950b89c515e183fbc57b2d Signed-off-by: agardner <agardner@linuxfoundation.org>
2018-01-26Linting should be done on a build server, not on masteragardner1-3/+3
Linting was broken by this patch https://gerrit.opnfv.org/gerrit/#/c/50737/ Also added sudo to pip installs, as they are not in a venv Patch forgot to put linting on build server so it defaulted to master. Change-Id: Iba8c1f633fad6d5f3d097f4911f45100c3b43e30 Signed-off-by: agardner <agardner@linuxfoundation.org>
2018-01-26Fix typo in lint-initAlex Yang1-1/+1
Change-Id: I310c4f2e46a26b35eeafef2dfc8670d70ace0575 Signed-off-by: Alex Yang <yangyang1@zte.com.cn>
2018-01-24add 'lint-all-code' as wrapper of lint buildersRyota MIBU1-97/+61
OPNFV has common coding style [1]. So, all repos shall be checked by one generic checker builder/job, eventually. This patch adds lint wrapper builder 'lint-all-code', and also refactors all exisiting lint and syntax check builders, following 'lint-yaml-code' builder approach, which only checks modified files. This approach is nice as it won't require immediate fixes of violations in whole repo code right after the lint checker job is enabled. Note that lint jobs are still configured to run against some project repo, in order to seperate discussion; wheter we should apply this lint job to all OPNFV repo or not immediately. [1] https://wiki.opnfv.org/display/DEV/Contribution+Guidelines Change-Id: Ib4ab3ba5dc08845f3016b8be772f4ed119f11b2d Signed-off-by: Ryota MIBU <r-mibu@cq.jp.nec.com>
2018-01-23Add GERRIT_REFSPEC to 'project-parameter' MacroTrevor Bramwell1-0/+4
GERRIT_REFSPEC is always passed by the gerrit-trigger plugin when a job is triggered by Gerrit. Because it is not explicily defined, there is no way to manually trigger jobs, as the git clone looks up the list of refs by GERRIT_REFSPEC. Being able to manually trigger jobs (with node parameters so they can be restricted) is very helpful in debugging CI issues. Change-Id: I8a1d9ea380902fc95f30482e5acb616347709ab1 Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2018-01-16Merge "Docker Builds from Git Tag"Trevor Bramwell1-1/+1
2018-01-15Add macro for reporting the provision resultJulien1-0/+26
1. add macro for report the provision result of installers and try it in daisy 2. update according to TestAPI interface Change-Id: Ic041744c917c37fcd84a12a92e927e39106cf18f Signed-off-by: Julien <zhang.jun3g@zte.com.cn>
2018-01-09Docker Builds from Git TagTrevor Bramwell1-1/+1
Facilitates the creation of docker images from tags pushed to Gerrit, which should remove the need to manually trigger 'tagged' builds. Fixes a typo in the 'gerrit-trigger-tag-created' macro, replaces 'RELEASE_VERSION' with 'GERRIT_REFNAME', and adds the tag-trigger to docker builds. Change-Id: I6d8f8f34b1c51d74bb98211dfae21c37cf9356fa Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2017-12-21xci: Create periodic jobs for upstream osaFatih Degirmenci1-0/+10
This change takes xci-verify-jobs as base and adjusts osa-periodic jobs to ensure they do what they are supposed to. The structure of periodic jobs is pretty similar to xci-verify-jobs and the differences comparing to them are - OPENSTACK_OSA_VERSION is set to master. - SCM type changed to git-scm from gerrit - Voting is removed. - Triggering will be done using pollscm to ensure we only run jobs when something changes upstream. Triggers are not enabled yet until the basics are verified working. This change requires https://gerrit.opnfv.org/gerrit/#/c/49275/ in order for periodic jobs to work as expected. Further changes are needed to finalize the structure. Change-Id: I8f6519ccce93e6b8b65509638294419459fd36e8 Signed-off-by: Fatih Degirmenci <fdegir@gmail.com>
2017-11-30Update Releng Testresults PTL MacroTrevor Bramwell1-1/+6
Send emails to Serena after weekly Anteater scans on the releng-testresults repository. Change-Id: Ic4d61137ea8e30985f5330651e8d2da37b71fca3 Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2017-11-29Fix Anteater Weekly Reporting JobTrevor Bramwell1-26/+18
- Does not output the full scan to the console log - Updates the email-ext defaults to include any *.log file in the root of the workspace. This should include securityaudit.log - Adds 'GERRIT_REFSPEC' to the list of job parameters as required by 'git-scm-gerrit' - Fixes email-ptl macros so projects with extra repos have the proper recipients. Change-Id: Ibf22bf0683fc1f88de07ef3bb4717769c6ea0174 Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2017-11-27Email Weekly Anteater Reports to PTLsTrevor Bramwell1-0/+501
Completely replaces the current weekly security scan job. Instead of publishing weekly security scan reports they will be emailed to individual project PTLs. Uses a modified copy of 'anteater-security-audit.sh' to ensure the security scan job is not affected in this change. A later change will be made to merge the file back in and update the jobs. This is why 'anteater-parameters' are added to both jobs-templates. Change-Id: Ia8ebffbfce7a2d4feb83ef68ff0ab0c7bb4d2104 Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2017-11-13Merge "fix the bug of patch verify"Trevor Bramwell1-1/+6
2017-11-10Remove Artifacts JSON JobTrevor Bramwell1-22/+0
As far as I know the site that consumed this resource was never actually published, and given this runs frequently on master, removing it should save resources. Change-Id: I383fcffcef98e0e12a38d15dcb1204419283b833 Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2017-11-09fix the bug of patch verifywutianwei1-1/+6
If one patch don't modify the "yml" or "yaml" file, the script will exit with 1 at egrep "ya?ml$", then mark build as failure. In my opinion, if not modify the "yml" or "yaml" file, the yamllint should be successful. So we need mark the result of egrep "ya?ml$" as true, then judge the $YAML_FILES. Change-Id: I8abcadc9e4c85935ac7b20cdf54713b9800108ba Signed-off-by: wutianwei <wutianwei1@huawei.com>
2017-11-08Sudo pip install.agardner1-1/+1
not in a venv, so build fails if called by jenkins user without sudo Change-Id: I612a20777cc70a33542f767a63075939782e3201 Signed-off-by: agardner <agardner@linuxfoundation.org>
2017-11-08Merge "Update Yamllint Version"Trevor Bramwell1-1/+1
2017-11-02Merge "Switch yamllint job to only run against new files"Trevor Bramwell1-7/+8
2017-11-02Need to change directory check for new docs verifyagardner1-1/+1
old dir is no longer generated grab dir created by tox -e docs Change-Id: If52e931f6abdc8dcb39fbe7aac3c6b3342ce81c8 Signed-off-by: agardner <agardner@linuxfoundation.org>
2017-11-02Merge "Move all doc verfication to docs-verify-rtd-*"Aric Gardner1-61/+1
2017-11-01Move all doc verfication to docs-verify-rtd-*agardner1-61/+1
Ready for review (tested locally) 1) remove opnfvdocs-daily-{stream}: We don't need a timed docs build. and it did not build anything usefull 2) remove opnfv-docs-verify-{stream}: This uses depreciated and unmaintained opnfvdocs/scripts/docs-build.sh It does not clone submodules and gives no usefull feedback but it does post to artifacts and give a gerrit comment move that functionality to docs-*-rtd-* 3) remove opnfv-docs-merge-{stream}: does not upload anything meaningful 4) remove macro upload-generated-docs-to-opnfv-artifacts: is no longer needed since we use read the docs 5) improve docs-verify-rtd-{stream}: generate single page html and post to artifacts send gerrit commment with location of single page html, errors (like malformed table) are embedded nicely in the single page output and give devs a single source of feedback on their work 6) improve docs-merge-rtd-{stream}: this job now needs to remove review documenation created by docs-verify-rtd-{stream} TODO, after this is merged: remove now unused opnfvdocs/scripts/docs-build.sh Change-Id: I802eb11712d42555d34f986d061bf0dfc623c1e9 Signed-off-by: agardner <agardner@linuxfoundation.org>
2017-10-31Add Gerrit Trigger on Tag CreationTrevor Bramwell1-0/+14
We should be able to capture a tag creation event by triggering on 'ref-updated' but looking specifically at the 'refs/tags/' branch prefix. Though this will trigger a build against a specific tag, scripts will still need to examine the GERRIT_REFSPEC to determine the tag name. Change-Id: Ic18a3e11530fb71735431240f93d2074dacf4e1c Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2017-10-18Switch yamllint job to only run against new filesTrevor Bramwell1-7/+8
Intead of yamllint all files at once yamllint will only run against new or modified yaml files. Change-Id: I10b951427966409e15fb773b959adbd780497bad Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2017-10-16Update Yamllint VersionTrevor Bramwell1-1/+1
1.6.0 is quite a bit out of date; Updating Yamllint to 1.8.2 will enable some nicer feature of yamllint (like single line rule disables). Change-Id: I88d1c14539516ccef4f5e2e7e95b0017503dd98f Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2017-09-08installers: Use global macro 'clean-workspace'Alexandru Avadanii1-0/+10
Change-Id: I34a555697d963efc38064a7b53f25191d6bf1382 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
2017-08-29Fix Yamllint Violations for jjb/globalTrevor Bramwell1-337/+338
Includes a default .yamllint configuration file with line-length producing a warning (instead of the default error) after 120 characters. JIRA: RELENG-254 Change-Id: Ia46ec6451201c5e91d98901a6ff65360079b2c81 Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
2017-08-17jjb: global: releng-macros: Add timeout wrapperMarkos Chandras1-0/+8
Add new timeout wrapper which can be used to kill a job if it take too long to finish Change-Id: I15a20fc92ea7855d11983b5734064aace138a2b5 Signed-off-by: Markos Chandras <mchandras@suse.de>
2017-08-02Create experimental job for qtip integrationYujun Zhang1-1/+1
Note that - experimental trigger is modified to allow trigger the build from changes outside `tests` folder - doctor jobs modified to adapt the change in common trigger Change-Id: Iaaa26651f9ea1d14cb6c77a713ff657c330dce6e Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
2017-07-10Merge "Send Build Notifications to Jenkins Admins"Trevor Bramwell1-0/+14
2017-06-23Send Build Notifications to Jenkins AdminsTrevor Bramwell1-0/+14
Given the number of jobs in OPNFV there isn't an easy way to discover when there is an issue affecting a large number of jobs without looking into individual job logs. By sending out email notifications on failed builds (using the email-ext plugin), we will have insight into causes for large sets of job failures, and also be able to identify non-job specific issues. This macro still needs to be added to jobs that already have publishers set, but by just adding it to defaults it should cover about half of all current jobs. JIRA: RELENG-257 Change-Id: I9d55bdd929a60004a16fa3c21bf1f7069f8786db Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>