9 - config-file-provider:
12 target: "$HOME/.config/jenkins_jobs/jenkins_jobs.ini"
14 - lf_packer: &lf_packer_common
15 name: lf-packer-common
16 # Provide configuration common in packer jobs.
18 ######################
19 # Default parameters #
20 ######################
26 github-url: "https://github.com"
28 submodule-recursive: true
30 submodule-disable: false
31 packer-cloud-settings: packer-cloud-env
38 project-type: freestyle
40 disabled: "{disable-job}"
43 - lf-infra-properties:
48 - lf-infra-parameters:
52 - lf-packer-parameters:
53 packer-version: "{packer-version}"
57 build-timeout: "{build-timeout}"
58 jenkins-ssh-credential: "{jenkins-ssh-credential}"
64 name: lf-infra-jjb-parameters
68 default: "{jjb-version}"
69 description: Jenkins Job Builder version to download and install.
72 default: "{jjb-cache}"
73 description: Jenkins Job Builder cache location.
76 name: lf-packer-parameters
80 default: "{packer-version}"
81 description: Packer version to download and install.
84 name: lf-puppet-parameters
87 name: PUPPET_LINT_VERSION
88 default: "{puppet-lint-version}"
89 description: Puppet-lint version to download and install.
91 - lf_jjb_common: &lf_jjb_common
94 ######################
95 # Default parameters #
96 ######################
101 github-url: "https://github.com"
102 jjb-cache: "$HOME/.cache/jenkins_jobs"
105 submodule-recursive: true
106 submodule-timeout: 10
107 submodule-disable: false
108 throttle_categories: []
109 throttle-enabled: false
110 throttle-max-per-node: 1
111 throttle-max-total: 0
112 throttle-option: "project"
114 gerrit_trigger_file_paths:
115 - compare-type: REG_EXP
117 - compare-type: REG_EXP
118 pattern: "global-jjb"
119 - compare-type: REG_EXP
122 # github_included_regions MUST match gerrit_trigger_file_paths
123 github_included_regions:
128 #####################
129 # Job Configuration #
130 #####################
132 project-type: freestyle
134 disabled: "{disable-job}"
137 - lf-infra-properties:
139 build-days-to-keep: 7
141 categories: "{obj:throttle_categories}"
142 enabled: "{throttle-enabled}"
143 max-per-node: "{throttle-max-per-node}"
144 max-total: "{throttle-max-total}"
145 option: "{throttle-option}"
148 - lf-infra-parameters:
152 - lf-infra-jjb-parameters:
153 jjb-cache: "{jjb-cache}"
154 jjb-version: "{jjb-version}"
158 build-timeout: "{build-timeout}"
159 jenkins-ssh-credential: "{jenkins-ssh-credential}"
164 ######################
165 # Gerrit Branch Lock #
166 ######################
169 name: "{project-name}-gerrit-branch-lock-{stream}"
170 id: gerrit-branch-lock
172 ######################
173 # Default parameters #
174 ######################
178 git-url: "$GIT_URL/$GERRIT_PROJECT"
180 submodule-timeout: 10
181 submodule-disable: false
182 gerrit_merge_triggers:
183 - comment-added-contains-event:
184 comment-contains-value: (un)?lock branch$
186 #####################
187 # Job Configuration #
188 #####################
190 project-type: freestyle
192 disabled: "{disable-job}"
195 - lf-infra-properties:
197 build-days-to-keep: 1
200 - lf-infra-parameters:
208 jenkins-ssh-credential: "{jenkins-ssh-credential}"
211 - lf-infra-gerrit-scm:
215 submodule-recursive: false
216 submodule-timeout: "{submodule-timeout}"
217 submodule-disable: "{submodule-disable}"
218 choosing-strategy: default
219 jenkins-ssh-credential: "{jenkins-ssh-credential}"
223 server-name: "{gerrit-server-name}"
224 trigger-on: "{obj:gerrit_merge_triggers}"
226 - project-compare-type: ANT
227 project-pattern: "{project}"
229 - branch-compare-type: ANT
230 branch-pattern: "**/{branch}"
233 - shell: !include-raw-escape: ../shell/gerrit-branch-lock.sh
238 ##########################################
239 # Jenkins Configuration Management Merge #
240 ##########################################
243 name: lf-jenkins-cfg-clouds
247 properties-content: "jenkins_silos={jenkins-silos}"
248 - shell: !include-raw-escape: ../shell/jenkins-configure-clouds.sh
249 - shell: rm -f "$HOME/.config/jenkins_jobs/jenkins_jobs.ini"
252 name: lf-jenkins-cfg-global-vars
256 properties-content: "jenkins_silos={jenkins-silos}"
257 - shell: !include-raw-escape: ../shell/jenkins-configure-global-vars.sh
258 - shell: rm -f "$HOME/.config/jenkins_jobs/jenkins_jobs.ini"
260 - lf_jenkins_configuration: &lf_jenkins_cfg_merge
261 name: lf-jenkins-cfg-merge
263 ######################
264 # Default parameters #
265 ######################
270 git-url: "$GIT_URL/$GERRIT_PROJECT"
271 github-url: "https://github.com"
272 jenkins-silos: production sandbox
273 submodule-timeout: 10
274 submodule-disable: false
276 gerrit_merge_triggers:
277 - change-merged-event
278 - comment-added-contains-event:
279 comment-contains-value: '^Patch Set\s+\d+:\s+remerge\s*$'
281 gerrit_trigger_file_paths:
282 - compare-type: REG_EXP
283 pattern: 'jenkins-config\/.*'
285 # github_included_regions MUST match gerrit_trigger_file_paths
286 github_included_regions:
287 - 'jenkins-config\/.*'
289 #####################
290 # Job Configuration #
291 #####################
293 project-type: freestyle
296 disabled: "{disable-job}"
299 - lf-infra-properties:
301 build-days-to-keep: 1
304 - lf-infra-parameters:
312 jenkins-ssh-credential: "{jenkins-ssh-credential}"
316 - lf-jenkins-cfg-global-vars:
317 jenkins-silos: "{jenkins-silos}"
318 - lf-jenkins-cfg-clouds:
319 jenkins-silos: "{jenkins-silos}"
325 name: "{project-name}-jenkins-cfg-merge"
326 id: gerrit-jenkins-cfg-merge
327 <<: *lf_jenkins_cfg_merge
330 - lf-infra-gerrit-scm:
332 refspec: "refs/heads/{branch}"
334 submodule-recursive: true
335 submodule-timeout: "{submodule-timeout}"
336 submodule-disable: "{submodule-disable}"
337 choosing-strategy: default
338 jenkins-ssh-credential: "{jenkins-ssh-credential}"
341 - timed: "{obj:cron}"
343 server-name: "{gerrit-server-name}"
344 trigger-on: "{obj:gerrit_merge_triggers}"
346 - project-compare-type: ANT
347 project-pattern: "{project}"
349 - branch-compare-type: ANT
350 branch-pattern: "**/{branch}"
351 file-paths: "{obj:gerrit_trigger_file_paths}"
354 name: "{project-name}-jenkins-cfg-merge"
355 id: github-jenkins-cfg-merge
356 <<: *lf_jenkins_cfg_merge
359 - lf-infra-properties:
361 build-days-to-keep: 1
363 url: "{github-url}/{github-org}/{project}"
366 - lf-infra-github-scm:
367 url: "{git-clone-url}{github-org}/{project}"
369 branch: "refs/heads/{branch}"
370 submodule-recursive: true
371 submodule-timeout: "{submodule-timeout}"
372 submodule-disable: "{submodule-disable}"
373 choosing-strategy: default
374 jenkins-ssh-credential: "{jenkins-ssh-credential}"
377 - timed: "{obj:cron}"
381 - github-pull-request:
382 trigger-phrase: "^remerge$"
383 only-trigger-phrase: true
384 status-context: "Jenkins CFG Merge"
389 white-list: "{obj:github_pr_whitelist}"
390 admin-list: "{obj:github_pr_admin_list}"
391 included-regions: "{obj:github_included_regions}"
392 white-list-target-branches:
395 ###########################################
396 # Jenkins Configuration Management Verify #
397 ###########################################
399 - lf_jenkins_configuration: &lf_jenkins_cfg_verify
400 name: lf-jenkins-cfg-verify
402 ######################
403 # Default parameters #
404 ######################
407 build-days-to-keep: 7
409 git-url: "$GIT_URL/$GERRIT_PROJECT"
410 github-url: "https://github.com"
411 submodule-timeout: 10
412 submodule-disable: false
414 gerrit_verify_triggers:
415 - patchset-created-event:
417 exclude-trivial-rebase: false
418 exclude-no-code-change: false
419 - draft-published-event
420 - comment-added-contains-event:
421 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
423 gerrit_trigger_file_paths:
424 - compare-type: REG_EXP
425 pattern: 'jenkins-config\/.*'
427 # github_included_regions MUST match gerrit_trigger_file_paths
428 github_included_regions:
429 - 'jenkins-config\/.*'
431 #####################
432 # Job Configuration #
433 #####################
435 project-type: freestyle
438 disabled: "{disable-job}"
441 - lf-infra-properties:
443 build-days-to-keep: 1
446 - lf-infra-parameters:
454 jenkins-ssh-credential: "{jenkins-ssh-credential}"
455 - config-file-provider:
456 # Listed after to override openstack-infra-wrappers clouds.yaml
459 - file-id: clouds-yaml
460 target: "$HOME/.config/openstack/clouds.yaml"
462 target: "$HOME/.npmrc"
464 target: "$HOME/.config/pip/pip.conf"
468 - shell: !include-raw-escape: ../shell/jenkins-verify-images.sh
474 name: "{project-name}-jenkins-cfg-verify"
475 id: gerrit-jenkins-cfg-verify
476 <<: *lf_jenkins_cfg_verify
479 - lf-infra-gerrit-scm:
481 refspec: "$GERRIT_REFSPEC"
482 branch: "$GERRIT_BRANCH"
483 submodule-recursive: true
484 submodule-timeout: "{submodule-timeout}"
485 submodule-disable: "{submodule-disable}"
486 choosing-strategy: gerrit
487 jenkins-ssh-credential: "{jenkins-ssh-credential}"
491 server-name: "{gerrit-server-name}"
492 trigger-on: "{obj:gerrit_verify_triggers}"
494 - project-compare-type: ANT
495 project-pattern: "{project}"
497 - branch-compare-type: ANT
498 branch-pattern: "**/{branch}"
499 file-paths: "{obj:gerrit_trigger_file_paths}"
502 name: "{project-name}-jenkins-cfg-verify"
503 id: github-jenkins-cfg-verify
504 <<: *lf_jenkins_cfg_verify
508 url: "{github-url}/{github-org}/{project}"
511 - lf-infra-github-scm:
512 url: "{git-clone-url}{github-org}/{project}"
513 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
515 submodule-recursive: true
516 submodule-timeout: "{submodule-timeout}"
517 submodule-disable: "{submodule-disable}"
518 choosing-strategy: default
519 jenkins-ssh-credential: "{jenkins-ssh-credential}"
522 - github-pull-request:
523 trigger-phrase: "^(recheck|reverify)$"
524 only-trigger-phrase: false
525 status-context: "Jenkins CFG Verify"
528 included-regions: "{obj:github_included_regions}"
529 white-list-target-branches:
532 ###########################
533 # JENKINS SANDBOX CLEANUP #
534 ###########################
536 - lf_jenkins_sandbox_cleanup: &lf_jenkins_sandbox_cleanup
537 name: lf-jenkins-sandbox-cleanup
539 ######################
540 # Default parameters #
541 ######################
544 # Run every Saturday at 08:00 UTC
548 #####################
549 # Job Configuration #
550 #####################
552 project-type: freestyle
555 disabled: "{disable-job}"
558 - lf-infra-jjb-parameters:
559 jjb-cache: "{jjb-cache}"
560 jjb-version: "{jjb-version}"
563 - timed: "{obj:cron}"
567 - shell: !include-raw-escape:
568 - ../shell/jenkins-sandbox-cleanup.sh
571 name: "{project-name}-jenkins-sandbox-cleanup"
572 id: gerrit-jenkins-sandbox-cleanup
574 # yamllint disable-line rule:key-duplicates
575 <<: *lf_jenkins_sandbox_cleanup
578 name: "{project-name}-jenkins-sandbox-cleanup"
579 id: github-jenkins-sandbox-cleanup
581 # yamllint disable-line rule:key-duplicates
582 <<: *lf_jenkins_sandbox_cleanup
588 - lf_jjb_deploy_job: &lf_jjb_deploy_job
589 name: lf-jjb-deploy-job
591 ######################
592 # Default parameters #
593 ######################
597 # jjb-deploy should always clone $PROJECT regardless of what
598 # $GERRIT_PROJECT triggered the job.
599 git-url: "$GIT_URL/$PROJECT"
600 github-url: "https://github.com"
602 submodule-timeout: 10
603 submodule-disable: false
604 gerrit_jjb_deploy_job_triggers:
605 - comment-added-contains-event:
606 comment-contains-value: '^Patch Set\s+\d+:\s+(jjb-deploy[:]* (?!\*+$).+$)'
608 #####################
609 # Job Configuration #
610 #####################
612 project-type: freestyle
615 disabled: "{disable-job}"
618 - lf-infra-properties:
620 build-days-to-keep: 1
623 - lf-infra-parameters:
631 jenkins-ssh-credential: "{jenkins-ssh-credential}"
635 pip-packages: jenkins-job-builder
637 - shell: !include-raw-escape: ../shell/jjb-deploy-job.sh
643 name: "{project-name}-jjb-deploy-job"
644 id: gerrit-jjb-deploy-job
645 <<: *lf_jjb_deploy_job
648 - lf-infra-gerrit-scm:
650 refspec: "refs/heads/{branch}"
652 submodule-recursive: true
653 submodule-timeout: "{submodule-timeout}"
654 submodule-disable: "{submodule-disable}"
655 choosing-strategy: default
656 jenkins-ssh-credential: "{jenkins-ssh-credential}"
660 server-name: "{gerrit-server-name}"
661 trigger-on: "{obj:gerrit_jjb_deploy_job_triggers}"
663 - project-compare-type: ANT
664 project-pattern: "**"
666 - branch-compare-type: ANT
675 name: "{project-name}-jjb-deploy-job"
676 id: github-jjb-deploy-job
677 <<: *lf_jjb_deploy_job
680 - lf-infra-properties:
682 build-days-to-keep: 1
684 url: "{github-url}/{github-org}/{project}"
687 - lf-infra-github-scm:
688 url: "{git-clone-url}{github-org}/{project}"
689 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
691 submodule-recursive: true
692 submodule-timeout: "{submodule-timeout}"
693 submodule-disable: "{submodule-disable}"
694 choosing-strategy: default
695 jenkins-ssh-credential: "{jenkins-ssh-credential}"
698 - github-pull-request:
699 trigger-phrase: '^jjb-deploy (?!\*+$).+$'
700 only-trigger-phrase: true
701 status-context: "JJB Deploy Job"
704 white-list-target-branches:
711 - lf_jjb_merge: &lf_jjb_merge
714 ######################
715 # Default parameters #
716 ######################
720 gerrit_merge_triggers:
721 - change-merged-event
722 - comment-added-contains-event:
723 comment-contains-value: '^Patch Set\s+\d+:\s+remerge\s*$'
725 #####################
726 # Job Configuration #
727 #####################
733 properties-content: JJB_WORKERS={jjb-workers}
734 - shell: !include-raw-escape:
735 - ../shell/jjb-merge-job.sh
738 name: "{project-name}-jjb-merge"
741 # yamllint disable-line rule:key-duplicates
744 git-url: "$GIT_URL/$GERRIT_PROJECT"
747 - lf-infra-gerrit-scm:
751 submodule-recursive: "{submodule-recursive}"
752 submodule-timeout: "{submodule-timeout}"
753 submodule-disable: "{submodule-disable}"
754 choosing-strategy: default
755 jenkins-ssh-credential: "{jenkins-ssh-credential}"
759 server-name: "{gerrit-server-name}"
760 trigger-on: "{obj:gerrit_merge_triggers}"
762 - project-compare-type: ANT
763 project-pattern: "{project}"
765 - branch-compare-type: ANT
766 branch-pattern: "**/{branch}"
767 file-paths: "{obj:gerrit_trigger_file_paths}"
770 name: "{project-name}-jjb-merge"
773 # yamllint disable-line rule:key-duplicates
776 #####################
777 # Job Configuration #
778 #####################
781 - lf-infra-properties:
783 build-days-to-keep: 7
785 url: "{github-url}/{github-org}/{project}"
788 - lf-infra-github-scm:
789 url: "{git-clone-url}{github-org}/{project}"
791 branch: "refs/heads/{branch}"
792 submodule-recursive: "{submodule-recursive}"
793 submodule-timeout: "{submodule-timeout}"
794 submodule-disable: "{submodule-disable}"
795 choosing-strategy: default
796 jenkins-ssh-credential: "{jenkins-ssh-credential}"
802 - github-pull-request:
803 trigger-phrase: "^remerge$"
804 only-trigger-phrase: true
805 status-context: "JJB Merge"
810 white-list: "{obj:github_pr_whitelist}"
811 admin-list: "{obj:github_pr_admin_list}"
812 included-regions: "{obj:github_included_regions}"
813 white-list-target-branches:
820 - lf_jjb_verify: &lf_jjb_verify
823 ######################
824 # Default parameters #
825 ######################
827 build-concurrent: true
829 gerrit_verify_triggers:
830 - patchset-created-event:
832 exclude-trivial-rebase: false
833 exclude-no-code-change: false
834 - draft-published-event
835 - comment-added-contains-event:
836 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
838 #####################
839 # Job Configuration #
840 #####################
842 concurrent: "{build-concurrent}"
847 - shell: !include-raw-escape:
848 - ../shell/jjb-verify-job.sh
849 - lf-infra-gpg-verify-git-signature
852 name: "{project-name}-jjb-verify"
853 id: gerrit-jjb-verify
855 # yamllint disable-line rule:key-duplicates
858 ######################
859 # Default parameters #
860 ######################
862 git-url: "$GIT_URL/$GERRIT_PROJECT"
864 #####################
865 # Job Configuration #
866 #####################
869 - lf-infra-gerrit-scm:
871 refspec: "$GERRIT_REFSPEC"
872 branch: "$GERRIT_BRANCH"
873 submodule-recursive: "{submodule-recursive}"
874 submodule-timeout: "{submodule-timeout}"
875 submodule-disable: "{submodule-disable}"
876 choosing-strategy: gerrit
877 jenkins-ssh-credential: "{jenkins-ssh-credential}"
881 server-name: "{gerrit-server-name}"
882 trigger-on: "{obj:gerrit_verify_triggers}"
884 - project-compare-type: ANT
885 project-pattern: "{project}"
887 - branch-compare-type: ANT
888 branch-pattern: "**/{branch}"
889 file-paths: "{obj:gerrit_trigger_file_paths}"
892 name: "{project-name}-jjb-verify"
893 id: github-jjb-verify
895 # yamllint disable-line rule:key-duplicates
898 #####################
899 # Job Configuration #
900 #####################
903 - lf-infra-properties:
905 build-days-to-keep: 7
907 url: "{github-url}/{github-org}/{project}"
910 - lf-infra-github-scm:
911 url: "{git-clone-url}{github-org}/{project}"
912 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
914 submodule-recursive: "{submodule-recursive}"
915 submodule-timeout: "{submodule-timeout}"
916 submodule-disable: "{submodule-disable}"
917 choosing-strategy: default
918 jenkins-ssh-credential: "{jenkins-ssh-credential}"
921 - github-pull-request:
922 trigger-phrase: "^(recheck|reverify)$"
923 only-trigger-phrase: false
924 status-context: "JJB Verify"
927 included-regions: "{obj:github_included_regions}"
928 white-list-target-branches:
931 ############################
932 # JJB Verify Upstream GJJB #
933 ############################
935 - lf_jjb_verify: &lf_jjb_verify_upstream_gjjb
936 name: lf-jjb-verify-upstream-gjjb
938 #####################
939 # Job Configuration #
940 #####################
947 git fetch https://gerrit.linuxfoundation.org/infra/releng/global-jjb $GERRIT_REFSPEC
948 git cherry-pick FETCH_HEAD
950 - shell: !include-raw-escape:
951 - ../shell/jjb-verify-job.sh
952 - lf-infra-gpg-verify-git-signature
955 name: "{project-name}-jjb-verify-upstream-gjjb"
956 id: gerrit-jjb-verify-upstream-gjjb
958 # yamllint disable-line rule:key-duplicates
959 <<: *lf_jjb_verify_upstream_gjjb
961 ######################
962 # Default parameters #
963 ######################
965 git-url: "$GIT_URL/$PROJECT"
966 submodule-timeout: 10
967 submodule-disable: false
969 #####################
970 # Job Configuration #
971 #####################
974 - lf-infra-gerrit-scm:
978 submodule-recursive: true
979 submodule-timeout: "{submodule-timeout}"
980 submodule-disable: "{submodule-disable}"
981 choosing-strategy: default
982 jenkins-ssh-credential: "{jenkins-ssh-credential}"
986 server-name: "LinuxFoundation"
988 - patchset-created-event:
990 exclude-trivial-rebase: false
991 exclude-no-code-change: false
992 - draft-published-event
993 - comment-added-contains-event:
994 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
996 - project-compare-type: ANT
997 project-pattern: "releng/global-jjb"
999 - branch-compare-type: ANT
1000 branch-pattern: "**/master"
1001 override-votes: true
1002 gerrit-build-failed-codereview-value: -1
1003 gerrit-build-failed-verified-value: 0
1004 gerrit-build-successful-codereview-value: 1
1005 gerrit-build-successful-verified-value: 0
1011 - lf_license_check: &lf_license_check
1012 name: lf-license-check
1014 ######################
1015 # Default parameters #
1016 ######################
1019 build-days-to-keep: 7
1028 git-url: "$GIT_URL/$PROJECT"
1029 github-url: "https://github.com"
1031 license-exclude-paths: ""
1032 licenses-allowed: Apache-2.0,EPL-1.0,MIT
1033 project-pattern: "**"
1036 submodule-timeout: 10
1037 submodule-disable: false
1039 #####################
1040 # Job Configuration #
1041 #####################
1043 project-type: freestyle
1044 node: "{build-node}"
1046 disabled: "{disable-job}"
1049 - lf-infra-properties:
1050 build-days-to-keep: "{build-days-to-keep}"
1053 - lf-infra-parameters:
1054 project: "{project}"
1059 - lf-infra-wrappers:
1060 build-timeout: "{build-timeout}"
1061 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1065 file-patterns: "{file-patterns}"
1066 spdx-disable: "{spdx-disable}"
1067 lhc-version: "{lhc-version}"
1068 license-exclude-paths: "{license-exclude-paths}"
1069 licenses-allowed: "{licenses-allowed}"
1075 name: "{project-name}-license-check"
1076 id: gerrit-license-check
1077 <<: *lf_license_check
1079 git-url: "$GIT_URL/$GERRIT_PROJECT"
1082 - lf-infra-gerrit-scm:
1083 git-url: "{git-url}"
1084 refspec: "$GERRIT_REFSPEC"
1085 branch: "$GERRIT_BRANCH"
1086 # Submodules are out of the project's control
1087 submodule-recursive: false
1088 submodule-timeout: "{submodule-timeout}"
1089 submodule-disable: "{submodule-disable}"
1090 choosing-strategy: gerrit
1091 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1095 server-name: "{gerrit-server-name}"
1096 # Trigger should not be overridable as we want to always run
1098 - patchset-created-event:
1099 exclude-drafts: false
1100 exclude-trivial-rebase: false
1101 exclude-no-code-change: false
1102 - draft-published-event
1103 - comment-added-contains-event:
1104 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
1106 - project-compare-type: ANT
1107 project-pattern: "{project-pattern}"
1109 - branch-compare-type: ANT
1110 branch-pattern: "**"
1113 name: "{project-name}-license-check"
1114 id: github-license-check
1115 <<: *lf_license_check
1118 - lf-infra-properties:
1119 build-days-to-keep: "{build-days-to-keep}"
1121 url: "{github-url}/{github-org}/{project}"
1124 - lf-infra-github-scm:
1125 url: "{git-clone-url}{github-org}/{project}"
1126 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
1128 # Submodules are out of the project's control
1129 submodule-recursive: false
1130 submodule-timeout: "{submodule-timeout}"
1131 submodule-disable: "{submodule-disable}"
1132 choosing-strategy: default
1133 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1136 - github-pull-request:
1137 trigger-phrase: "^recheck$"
1138 only-trigger-phrase: false
1139 status-context: "License Check"
1142 white-list-target-branches:
1145 ####################
1146 # Info YAML Verify #
1147 ####################
1149 - lf_info_yaml_verify: &lf_info_yaml_verify
1150 name: lf-info-yaml-verify
1152 ######################
1153 # Default parameters #
1154 ######################
1156 gerrit_verify_triggers:
1157 - patchset-created-event:
1158 exclude-drafts: true
1159 exclude-trivial-rebase: false
1160 exclude-no-code-change: false
1161 - draft-published-event
1162 - comment-added-contains-event:
1163 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
1165 #####################
1166 # Job Configuration #
1167 #####################
1172 - shell: !include-raw-escape:
1173 - ../shell/git-validate-info-yaml.sh
1174 - ../shell/info-file-validate.sh
1177 name: "{project-name}-info-yaml-verify"
1178 id: gerrit-info-yaml-verify
1180 # yamllint disable-line rule:key-duplicates
1181 <<: *lf_info_yaml_verify
1183 git-url: "$GIT_URL/$GERRIT_PROJECT"
1186 - lf-infra-gerrit-scm:
1187 git-url: "{git-url}"
1188 refspec: "$GERRIT_REFSPEC"
1189 branch: "$GERRIT_BRANCH"
1190 submodule-recursive: "{submodule-recursive}"
1191 submodule-timeout: "{submodule-timeout}"
1192 submodule-disable: "{submodule-disable}"
1193 choosing-strategy: gerrit
1194 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1198 server-name: "{gerrit-server-name}"
1199 trigger-on: "{obj:gerrit_verify_triggers}"
1201 - project-compare-type: ANT
1202 project-pattern: "{project}"
1204 - branch-compare-type: ANT
1205 branch-pattern: "**/{branch}"
1207 - compare-type: REG_EXP
1208 pattern: "INFO.yaml"
1211 name: "{project-name}-info-yaml-verify"
1212 id: github-info-yaml-verify
1214 # yamllint disable-line rule:key-duplicates
1215 <<: *lf_info_yaml_verify
1217 github-url: "https://github.com"
1220 url: "{github-url}/{github-org}/{project}"
1223 - lf-infra-github-scm:
1224 url: "{git-clone-url}{github-org}/{project}"
1225 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
1227 submodule-recursive: "{submodule-recursive}"
1228 submodule-timeout: "{submodule-timeout}"
1229 submodule-disable: "{submodule-disable}"
1230 choosing-strategy: default
1231 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1234 - github-pull-request:
1235 trigger-phrase: "^(recheck|reverify)$"
1236 only-trigger-phrase: false
1237 status-context: "INFO File Verify"
1240 # included-regions MUST match gerrit file-paths
1241 included-regions: "INFO.yaml"
1242 white-list-target-branches:
1249 - lf_openstack_cron: &lf_openstack_cron
1250 name: lf-openstack-cron
1252 ######################
1253 # Default parameters #
1254 ######################
1257 build-days-to-keep: 7
1261 git-url: "$GIT_URL/$PROJECT"
1262 github-url: "https://github.com"
1263 openstack-cloud: vex
1264 openstack-image-cleanup: true
1265 openstack-image-cleanup-age: 30
1266 openstack-image-protect: true
1267 openstack-port-cleanup: true
1268 openstack-server-cleanup: true
1269 openstack-stack-cleanup: true
1270 openstack-volume-cleanup: true
1272 submodule-timeout: 10
1273 submodule-disable: false
1275 #####################
1276 # Job Configuration #
1277 #####################
1279 project-type: freestyle
1280 node: "{build-node}"
1282 disabled: "{disable-job}"
1285 - lf-infra-properties:
1286 build-days-to-keep: "{build-days-to-keep}"
1289 - lf-infra-parameters:
1290 project: "{project}"
1295 default: "{jenkins-urls}"
1297 Space separated list of Jenkins URLs to check for active builds.
1300 - lf-infra-wrappers:
1301 build-timeout: "{build-timeout}"
1302 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1303 # Listed after to override openstack-infra-wrappers clouds.yaml definition
1304 - config-file-provider:
1306 - file-id: clouds-yaml
1307 target: "$HOME/.config/openstack/clouds.yaml"
1309 target: "$HOME/.npmrc"
1311 target: "$HOME/.config/pip/pip.conf"
1314 - timed: "{obj:cron}"
1317 - lf-infra-pre-build
1319 properties-content: OS_CLOUD={openstack-cloud}
1322 condition-kind: boolean-expression
1323 condition-expression: "{openstack-stack-cleanup}"
1325 - shell: !include-raw-escape: ../shell/openstack-cleanup-orphaned-stacks.sh
1328 condition-kind: boolean-expression
1329 condition-expression: "{openstack-server-cleanup}"
1331 - shell: !include-raw-escape: ../shell/openstack-cleanup-orphaned-servers.sh
1334 condition-kind: boolean-expression
1335 condition-expression: "{openstack-port-cleanup}"
1337 - shell: !include-raw-escape: ../shell/openstack-cleanup-orphaned-ports.sh
1340 condition-kind: boolean-expression
1341 condition-expression: "{openstack-volume-cleanup}"
1343 - shell: !include-raw-escape: ../shell/openstack-cleanup-orphaned-volumes.sh
1346 condition-kind: boolean-expression
1347 condition-expression: "{openstack-image-protect}"
1349 - shell: !include-raw-escape: ../shell/openstack-protect-in-use-images.sh
1351 condition-kind: boolean-expression
1352 condition-expression: "{openstack-image-cleanup}"
1355 properties-content: OS_IMAGE_CLEANUP_AGE={openstack-image-cleanup-age}
1356 - shell: !include-raw-escape: ../shell/openstack-cleanup-old-images.sh
1362 name: "{project-name}-openstack-cron"
1363 id: gerrit-openstack-cron
1364 <<: *lf_openstack_cron
1367 - lf-infra-gerrit-scm:
1368 git-url: "{git-url}"
1369 refspec: "refs/heads/{branch}"
1371 submodule-recursive: true
1372 submodule-timeout: "{submodule-timeout}"
1373 submodule-disable: "{submodule-disable}"
1374 choosing-strategy: default
1375 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1378 name: "{project-name}-openstack-cron"
1379 id: github-openstack-cron
1380 <<: *lf_openstack_cron
1383 - lf-infra-github-scm:
1384 url: "{git-clone-url}{github-org}/{project}"
1386 branch: "refs/heads/{branch}"
1387 submodule-recursive: true
1388 submodule-timeout: "{submodule-timeout}"
1389 submodule-disable: "{submodule-disable}"
1390 choosing-strategy: default
1391 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1397 - lf_packer_merge: &lf_packer_merge
1398 name: lf-packer-merge
1400 ######################
1401 # Default parameters #
1402 ######################
1405 openstack-cloud: vex
1406 update-cloud-image: false
1408 #####################
1409 # Job Configuration #
1410 #####################
1413 - lf-infra-parameters:
1414 project: "{project}"
1417 - lf-packer-parameters:
1418 packer-version: "{packer-version}"
1420 name: UPDATE_CLOUD_IMAGE
1421 default: "{update-cloud-image}"
1422 description: "Update new built image on the cloud."
1425 - lf-infra-packer-build:
1426 openstack: "{openstack}"
1427 openstack-cloud: "{openstack-cloud}"
1428 packer-cloud-settings: "{packer-cloud-settings}"
1429 packer-version: "{packer-version}"
1430 platform: "{platforms}"
1431 template: "{templates}"
1432 update-cloud-image: "{update-cloud-image}"
1433 - description-setter:
1434 regexp: '(\s+.*)(ZZCI\s+.*\d+-\d+\.\d+)'
1435 description: 'Image: \2'
1437 # - project: '{project-name}-openstack-update-cloud-image'
1439 # predefined-parameters: |
1440 # GERRIT_BRANCH=$GERRIT_BRANCH
1441 # GERRIT_PROJECT=$GERRIT_PROJECT
1442 # GERRIT_REFSPEC=$GERRIT_REFSPEC
1443 # NEW_IMAGE_NAME=$NEW_IMAGE_NAME
1444 # property-file: variables.jenkins-trigger
1445 # property-file-fail-on-missing: true
1449 - trigger-parameterized-builds:
1450 - project: "{project-name}-openstack-update-cloud-image"
1451 condition: UNSTABLE_OR_BETTER
1452 predefined-parameters: |
1453 NEW_IMAGE_NAME=$NEW_IMAGE_NAME
1454 property-file: variables.jenkins-trigger
1455 fail-on-missing: true
1458 name: "{project-name}-packer-merge-{platforms}-{templates}"
1459 id: gerrit-packer-merge
1460 <<: *lf_packer_common
1461 # yamllint disable-line rule:key-duplicates
1462 <<: *lf_packer_merge
1464 ######################
1465 # Default parameters #
1466 ######################
1468 git-url: "$GIT_URL/$GERRIT_PROJECT"
1470 gerrit_merge_triggers:
1471 - change-merged-event
1472 - comment-added-contains-event:
1473 comment-contains-value: '^Patch Set\s+\d+:\s+remerge\s*$'
1475 #####################
1476 # Job Configuration #
1477 #####################
1480 - lf-infra-gerrit-scm:
1481 git-url: "{git-url}"
1482 refspec: "$GERRIT_REFSPEC"
1483 branch: "$GERRIT_BRANCH"
1484 submodule-recursive: "{submodule-recursive}"
1485 submodule-timeout: "{submodule-timeout}"
1486 submodule-disable: "{submodule-disable}"
1487 choosing-strategy: default
1488 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1491 - timed: "{obj:cron}"
1493 server-name: "{gerrit-server-name}"
1494 trigger-on: "{obj:gerrit_merge_triggers}"
1496 - project-compare-type: ANT
1497 project-pattern: "{project}"
1499 - branch-compare-type: ANT
1500 branch-pattern: "**/{branch}"
1502 - compare-type: REG_EXP
1503 pattern: 'packer\/provision\/.*\.sh'
1504 - compare-type: REG_EXP
1505 pattern: 'packer\/provision\/.*\.bat'
1506 - compare-type: REG_EXP
1507 pattern: 'packer\/provision\/.*\.ps1'
1508 - compare-type: REG_EXP
1509 pattern: 'packer\/provision\/{templates}\.yaml'
1510 - compare-type: REG_EXP
1511 pattern: 'packer\/provision\/local-{templates}\.yaml'
1512 - compare-type: REG_EXP
1513 pattern: 'packer\/templates\/{templates}\.json'
1514 - compare-type: REG_EXP
1515 pattern: 'packer\/vars\/{platforms}\.json'
1518 name: "{project-name}-packer-merge-{platforms}-{templates}"
1519 id: github-packer-merge
1520 <<: *lf_packer_common
1521 # yamllint disable-line rule:key-duplicates
1522 <<: *lf_packer_merge
1524 #####################
1525 # Job Configuration #
1526 #####################
1529 - lf-infra-properties:
1530 project: "{project}"
1531 build-days-to-keep: 7
1533 url: "{github-url}/{github-org}/{project}"
1536 - lf-infra-github-scm:
1537 url: "{git-clone-url}{github-org}/{project}"
1539 +refs/heads/*:refs/remotes/origin/*
1540 +refs/pull/*:refs/remotes/origin/pr/*
1541 branch: "$GERRIT_REFSPEC"
1542 submodule-recursive: "{submodule-recursive}"
1543 submodule-timeout: "{submodule-timeout}"
1544 submodule-disable: "{submodule-disable}"
1545 choosing-strategy: default
1546 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1549 - timed: "{obj:cron}"
1554 - github-pull-request:
1555 trigger-phrase: "^remerge$"
1556 only-trigger-phrase: true
1557 status-context: "Packer {platforms}-{templates} Merge"
1562 white-list: "{obj:github_pr_whitelist}"
1563 admin-list: "{obj:github_pr_admin_list}"
1564 # included-regions MUST match Gerrit Trigger file-paths
1566 - 'packer\/provision\/.*\.sh'
1567 - 'packer\/provision\/.*\.bat'
1568 - 'packer\/provision\/.*\.ps1'
1569 - 'packer\/provision\/{templates}\.yaml'
1570 - 'packer\/provision\/local-{templates}\.yaml'
1571 - 'packer\/templates\/{templates}\.json'
1572 - 'packer\/vars\/{platforms}\.json'
1573 white-list-target-branches:
1580 - lf_packer_verify: &lf_packer_verify
1581 name: lf-packer-verify
1583 ######################
1584 # Default parameters #
1585 ######################
1589 openstack-cloud: vex
1591 gerrit_verify_triggers:
1592 - patchset-created-event:
1593 exclude-drafts: true
1594 exclude-trivial-rebase: false
1595 exclude-no-code-change: false
1596 - draft-published-event
1597 - comment-added-contains-event:
1598 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
1600 gerrit_trigger_file_paths:
1601 - compare-type: REG_EXP
1602 pattern: 'packer\/.*'
1604 # github_included_regions MUST match gerrit_trigger_file_paths
1605 github_included_regions:
1608 #####################
1609 # Job Configuration #
1610 #####################
1615 - lf-infra-packer-validate:
1616 openstack: "{openstack}"
1617 openstack-cloud: "{openstack-cloud}"
1618 packer-cloud-settings: "{packer-cloud-settings}"
1619 packer-version: "{packer-version}"
1622 name: "{project-name}-packer-verify"
1623 id: gerrit-packer-verify
1624 <<: *lf_packer_common
1625 # yamllint disable-line rule:key-duplicates
1626 <<: *lf_packer_verify
1628 ######################
1629 # Default parameters #
1630 ######################
1632 git-url: "$GIT_URL/$GERRIT_PROJECT"
1634 #####################
1635 # Job Configuration #
1636 #####################
1639 - lf-infra-gerrit-scm:
1640 git-url: "{git-url}"
1641 refspec: "$GERRIT_REFSPEC"
1642 branch: "$GERRIT_BRANCH"
1643 submodule-recursive: "{submodule-recursive}"
1644 submodule-timeout: "{submodule-timeout}"
1645 submodule-disable: "{submodule-disable}"
1646 choosing-strategy: gerrit
1647 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1651 server-name: "{gerrit-server-name}"
1652 trigger-on: "{obj:gerrit_verify_triggers}"
1654 - project-compare-type: ANT
1655 project-pattern: "{project}"
1657 - branch-compare-type: ANT
1658 branch-pattern: "**/{branch}"
1659 file-paths: "{obj:gerrit_trigger_file_paths}"
1662 name: "{project-name}-packer-verify"
1663 id: github-packer-verify
1664 <<: *lf_packer_common
1665 # yamllint disable-line rule:key-duplicates
1666 <<: *lf_packer_verify
1668 #####################
1669 # Job Configuration #
1670 #####################
1673 - lf-infra-properties:
1674 project: "{project}"
1675 build-days-to-keep: 7
1677 url: "{github-url}/{github-org}/{project}"
1680 - lf-infra-github-scm:
1681 url: "{git-clone-url}{github-org}/{project}"
1682 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
1684 submodule-recursive: "{submodule-recursive}"
1685 submodule-timeout: "{submodule-timeout}"
1686 submodule-disable: "{submodule-disable}"
1687 choosing-strategy: default
1688 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1691 - github-pull-request:
1692 trigger-phrase: "^(recheck|reverify)$"
1693 only-trigger-phrase: false
1694 status-context: "Packer Verify"
1697 included-regions: "{obj:github_included_regions}"
1698 white-list-target-branches:
1701 ################################
1702 # Openstack Update Cloud Image #
1703 ################################
1705 - lf_openstack_cron: &lf_openstack_update_cloud_image
1706 name: lf-openstack-update-cloud-image
1708 ######################
1709 # Default parameters #
1710 ######################
1713 build-days-to-keep: 7
1717 git-url: "$GIT_URL/$PROJECT"
1718 github-url: "https://github.com"
1719 new-image-name: "all"
1720 openstack-cloud: vex
1722 submodule-timeout: 10
1723 submodule-disable: false
1724 update-cloud-image: false
1726 #####################
1727 # Job Configuration #
1728 #####################
1730 project-type: freestyle
1731 node: "{build-node}"
1733 disabled: "{disable-job}"
1736 - lf-infra-properties:
1737 build-days-to-keep: "{build-days-to-keep}"
1740 - lf-infra-parameters:
1741 project: "{project}"
1745 name: NEW_IMAGE_NAME
1746 default: "{new-image-name}"
1747 description: "Name of cloud image to update in Jenkins"
1750 - lf-infra-wrappers:
1751 build-timeout: "{build-timeout}"
1752 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1753 # Listed after to override openstack-infra-wrappers clouds.yaml definition
1754 - config-file-provider:
1756 - file-id: clouds-yaml
1757 target: "$HOME/.config/openstack/clouds.yaml"
1759 target: "$HOME/.npmrc"
1761 target: "$HOME/.config/pip/pip.conf"
1764 - lf-infra-pre-build
1766 properties-content: |
1767 OS_CLOUD={openstack-cloud}
1770 echo "Extract the image type for commit message"
1771 # echo IMAGE_TYPE=${{NEW_IMAGE_NAME% -*}} >> image-type.txt
1772 IMAGE_TYPE=$(echo ${{NEW_IMAGE_NAME}} | tr -d "\'\"\ " | awk -F- '{{ print $2 " " $3 " " $4 }}')
1773 echo IMAGE_TYPE=${{IMAGE_TYPE}} >> image-type.txt
1776 properties-file: "image-type.txt"
1777 - lf-infra-update-packer-images
1778 - lf-infra-push-gerrit-patch:
1779 project: "{project}"
1780 gerrit-user: "{gerrit-user}"
1781 gerrit-host: "{gerrit-host}"
1782 gerrit-topic: "{gerrit-topic}"
1783 gerrit-commit-message: "Update cloud image $IMAGE_TYPE"
1784 reviewers-email: "{reviewers-email}"
1790 name: "{project-name}-openstack-update-cloud-image"
1791 id: gerrit-openstack-update-cloud-image
1792 <<: *lf_openstack_update_cloud_image
1794 ######################
1795 # Default parameters #
1796 ######################
1798 git-url: "$GIT_URL/$GERRIT_PROJECT"
1800 #####################
1801 # Job Configuration #
1802 #####################
1805 - lf-infra-gerrit-scm:
1806 git-url: "{git-url}"
1807 refspec: "$GERRIT_REFSPEC"
1808 branch: "$GERRIT_BRANCH"
1809 submodule-recursive: false
1810 submodule-timeout: "{submodule-timeout}"
1811 submodule-disable: "{submodule-disable}"
1812 choosing-strategy: gerrit
1813 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1816 - timed: "{obj:cron}"
1822 - lf_puppet_verify: &lf_puppet_verify
1823 name: lf-puppet-verify
1825 ######################
1826 # Default parameters #
1827 ######################
1830 build-days-to-keep: 7
1833 git-url: "$GIT_URL/$GERRIT_PROJECT"
1834 github-url: "https://github.com"
1837 puppet-lint-version: 2.3.6
1839 submodule-recursive: true
1840 submodule-timeout: 10
1841 submodule-disable: false
1843 gerrit_trigger_file_paths:
1844 - compare-type: REG_EXP
1847 # github_included_regions MUST match gerrit_trigger_file_paths
1848 github_included_regions:
1851 #####################
1852 # Job Configuration #
1853 #####################
1855 project-type: freestyle
1856 node: "{build-node}"
1858 disabled: "{disable-job}"
1861 - lf-infra-properties:
1862 build-days-to-keep: "{build-days-to-keep}"
1865 - lf-infra-parameters:
1866 project: "{project}"
1869 - lf-puppet-parameters:
1870 puppet-lint-version: "{puppet-lint-version}"
1873 - lf-infra-wrappers:
1874 build-timeout: "{build-timeout}"
1875 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1878 - shell: !include-raw-escape: ../shell/puppet-lint.sh
1884 name: "{project-name}-puppet-verify"
1885 id: gerrit-puppet-verify
1886 <<: *lf_puppet_verify
1888 ######################
1889 # Default parameters #
1890 ######################
1892 gerrit_verify_triggers:
1893 - patchset-created-event:
1894 exclude-drafts: true
1895 exclude-trivial-rebase: false
1896 exclude-no-code-change: false
1897 - draft-published-event
1898 - comment-added-contains-event:
1899 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
1901 #####################
1902 # Job Configuration #
1903 #####################
1906 - lf-infra-gerrit-scm:
1907 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1908 git-url: "{git-url}"
1909 refspec: "$GERRIT_REFSPEC"
1910 branch: "$GERRIT_BRANCH"
1911 submodule-recursive: "{submodule-recursive}"
1912 submodule-timeout: "{submodule-timeout}"
1913 submodule-disable: "{submodule-disable}"
1914 choosing-strategy: gerrit
1918 server-name: "{gerrit-server-name}"
1919 trigger-on: "{obj:gerrit_verify_triggers}"
1921 - project-compare-type: ANT
1922 project-pattern: "{project}"
1924 - branch-compare-type: ANT
1925 branch-pattern: "**/{branch}"
1926 file-paths: "{obj:gerrit_trigger_file_paths}"
1929 name: "{project-name}-puppet-verify"
1930 id: github-puppet-verify
1931 <<: *lf_puppet_verify
1933 #####################
1934 # Job Configuration #
1935 #####################
1938 - lf-infra-properties:
1939 project: "{project}"
1940 build-days-to-keep: 7
1942 url: "{github-url}/{github-org}/{project}"
1945 - lf-infra-github-scm:
1946 url: "{git-clone-url}{github-org}/{project}"
1947 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
1949 submodule-recursive: "{submodule-recursive}"
1950 submodule-timeout: "{submodule-timeout}"
1951 submodule-disable: "{submodule-disable}"
1952 choosing-strategy: default
1953 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1956 - github-pull-request:
1957 trigger-phrase: "^(recheck|reverify)$"
1958 only-trigger-phrase: false
1959 status-context: "Puppet Verify"
1962 included-regions: "{obj:github_included_regions}"
1963 white-list-target-branches:
1970 - lf_sonar_common: &lf_sonar_common
1971 name: lf-sonar-common
1973 ######################
1974 # Default parameters #
1975 ######################
1977 archive-artifacts: >
1980 branch: master # Sonar should always be run on master branch
1981 build-days-to-keep: 7
1983 cron: "H H * * *" # run daily
1985 git-url: "$GIT_URL/$PROJECT"
1986 github-url: "https://github.com"
1988 submodule-recursive: true
1989 submodule-timeout: 10
1990 submodule-disable: false
1994 sonar-project-file: "sonar-project.properties"
1995 sonar-properties: ""
1997 sonar-additional-args: ""
1999 gerrit_trigger_file_paths:
2000 - compare-type: REG_EXP
2003 # github_included_regions MUST match gerrit_trigger_file_paths
2004 github_included_regions:
2007 #####################
2008 # Job Configuration #
2009 #####################
2011 project-type: freestyle
2012 node: "{build-node}"
2015 - lf-infra-properties:
2016 build-days-to-keep: "{build-days-to-keep}"
2019 - lf-infra-wrappers:
2020 build-timeout: "{build-timeout}"
2021 jenkins-ssh-credential: "{jenkins-ssh-credential}"
2023 disabled: "{disable-job}"
2026 - lf-infra-parameters:
2027 project: "{project}"
2031 name: ARCHIVE_ARTIFACTS
2032 default: "{archive-artifacts}"
2033 description: Artifacts to archive to the logs server.
2038 - lf_sonar_builders: &lf_sonar_builders
2039 name: lf-sonar-builders
2041 - lf-infra-pre-build
2043 sonar-task: "{sonar-task}"
2044 sonar-project-file: "{sonar-project-file}"
2045 sonar-properties: "{sonar-properties}"
2046 sonar-java-opts: "{sonar-java-opts}"
2047 sonar-additional-args: "{sonar-additional-args}"
2049 - lf_sonar_builders_prescan: &lf_sonar_builders_prescan
2050 name: lf-sonar-builders-prescan
2052 - lf-infra-pre-build
2053 - lf-infra-sonar-with-prescan:
2054 sonar-task: "{sonar-task}"
2055 sonar-project-file: "{sonar-project-file}"
2056 sonar-properties: "{sonar-properties}"
2057 sonar-java-opts: "{sonar-java-opts}"
2058 sonar-additional-args: "{sonar-additional-args}"
2060 - lf_sonar_gerrit_common: &lf_sonar_gerrit_common
2061 name: lf-sonar-gerrit-common
2062 gerrit_sonar_triggers:
2063 - comment-added-contains-event:
2064 comment-contains-value: '^Patch Set\s+\d+:\s+run-sonar\s*$'
2067 - lf-infra-gerrit-scm:
2068 jenkins-ssh-credential: "{jenkins-ssh-credential}"
2069 git-url: "{git-url}"
2070 refspec: $GERRIT_REFSPEC
2071 branch: $GERRIT_BRANCH
2072 submodule-recursive: "{submodule-recursive}"
2073 submodule-timeout: "{submodule-timeout}"
2074 submodule-disable: "{submodule-disable}"
2075 choosing-strategy: default
2078 - timed: "{obj:cron}"
2080 server-name: "{gerrit-server-name}"
2081 trigger-on: "{obj:gerrit_sonar_triggers}"
2083 - project-compare-type: "ANT"
2084 project-pattern: "{project}"
2086 - branch-compare-type: "ANT"
2087 branch-pattern: "**/{branch}"
2088 file-paths: "{obj:gerrit_trigger_file_paths}"
2095 - lf_sonar_github_common: &lf_sonar_github_common
2096 name: lf-sonar-github-common
2098 - lf-infra-properties:
2099 build-days-to-keep: "{build-days-to-keep}"
2101 url: "{github-url}/{github-org}/{project}"
2104 - lf-infra-github-scm:
2105 url: "{git-clone-url}{github-org}/{project}"
2106 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
2108 submodule-recursive: "{submodule-recursive}"
2109 submodule-timeout: "{submodule-timeout}"
2110 submodule-disable: "{submodule-disable}"
2111 choosing-strategy: default
2112 jenkins-ssh-credential: "{jenkins-ssh-credential}"
2115 - github-pull-request:
2116 trigger-phrase: "^run-sonar$"
2117 only-trigger-phrase: false
2118 status-context: "Python Sonar"
2121 white-list-target-branches:
2123 included-regions: "{obj:github_included_regions}"
2126 name: "{project-name}-sonar"
2128 <<: *lf_sonar_common
2129 # yamllint disable-line rule:key-duplicates
2130 <<: *lf_sonar_builders
2131 # yamllint disable-line rule:key-duplicates
2132 <<: *lf_sonar_gerrit_common
2135 name: "{project-name}-sonar"
2137 <<: *lf_sonar_common
2138 # yamllint disable-line rule:key-duplicates
2139 <<: *lf_sonar_builders
2140 # yamllint disable-line rule:key-duplicates
2141 <<: *lf_sonar_github_common
2144 name: "{project-name}-sonar-prescan"
2145 id: gerrit-sonar-prescan
2146 <<: *lf_sonar_common
2147 # yamllint disable-line rule:key-duplicates
2148 <<: *lf_sonar_builders_prescan
2149 # yamllint disable-line rule:key-duplicates
2150 <<: *lf_sonar_gerrit_common
2153 name: "{project-name}-sonar-prescan"
2154 id: github-sonar-prescan
2155 <<: *lf_sonar_common
2156 # yamllint disable-line rule:key-duplicates
2157 <<: *lf_sonar_builders_prescan
2158 # yamllint disable-line rule:key-duplicates
2159 <<: *lf_sonar_github_common