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"
170 id: gerrit-branch-lock
172 ######################
173 # Default parameters #
174 ######################
178 git-url: "$GIT_URL/$GERRIT_PROJECT"
179 submodule-timeout: 10
180 submodule-disable: true
181 gerrit_merge_triggers:
182 - comment-added-contains-event:
183 comment-contains-value: (un)?lock branch$
185 #####################
186 # Job Configuration #
187 #####################
189 project-type: freestyle
191 disabled: "{disable-job}"
194 - lf-infra-properties:
196 build-days-to-keep: 1
199 - lf-infra-parameters:
207 jenkins-ssh-credential: "{jenkins-ssh-credential}"
210 - lf-infra-gerrit-scm:
213 branch: "$GERRIT_BRANCH"
214 submodule-recursive: false
215 submodule-timeout: "{submodule-timeout}"
216 submodule-disable: "{submodule-disable}"
217 choosing-strategy: default
218 jenkins-ssh-credential: "{jenkins-ssh-credential}"
222 server-name: "{gerrit-server-name}"
223 trigger-on: "{obj:gerrit_merge_triggers}"
225 - project-compare-type: ANT
226 project-pattern: "**"
228 - branch-compare-type: ANT
229 branch-pattern: "**/{branch}"
232 - shell: !include-raw-escape: ../shell/gerrit-branch-lock.sh
237 ##########################################
238 # Jenkins Configuration Management Merge #
239 ##########################################
242 name: lf-jenkins-cfg-clouds
246 properties-content: "jenkins_silos={jenkins-silos}"
247 - shell: !include-raw-escape: ../shell/jenkins-configure-clouds.sh
248 - shell: rm -f "$HOME/.config/jenkins_jobs/jenkins_jobs.ini"
251 name: lf-jenkins-cfg-global-vars
255 properties-content: "jenkins_silos={jenkins-silos}"
256 - shell: !include-raw-escape: ../shell/jenkins-configure-global-vars.sh
257 - shell: rm -f "$HOME/.config/jenkins_jobs/jenkins_jobs.ini"
259 - lf_jenkins_configuration: &lf_jenkins_cfg_merge
260 name: lf-jenkins-cfg-merge
262 ######################
263 # Default parameters #
264 ######################
269 git-url: "$GIT_URL/$GERRIT_PROJECT"
270 github-url: "https://github.com"
271 jenkins-silos: production sandbox
272 submodule-timeout: 10
273 submodule-disable: false
275 gerrit_merge_triggers:
276 - change-merged-event
277 - comment-added-contains-event:
278 comment-contains-value: '^Patch Set\s+\d+:\s+remerge\s*$'
280 gerrit_trigger_file_paths:
281 - compare-type: REG_EXP
282 pattern: 'jenkins-config\/.*'
284 # github_included_regions MUST match gerrit_trigger_file_paths
285 github_included_regions:
286 - 'jenkins-config\/.*'
288 #####################
289 # Job Configuration #
290 #####################
292 project-type: freestyle
295 disabled: "{disable-job}"
298 - lf-infra-properties:
300 build-days-to-keep: 1
303 - lf-infra-parameters:
311 jenkins-ssh-credential: "{jenkins-ssh-credential}"
315 - lf-jenkins-cfg-global-vars:
316 jenkins-silos: "{jenkins-silos}"
317 - lf-jenkins-cfg-clouds:
318 jenkins-silos: "{jenkins-silos}"
324 name: "{project-name}-jenkins-cfg-merge"
325 id: gerrit-jenkins-cfg-merge
326 <<: *lf_jenkins_cfg_merge
329 - lf-infra-gerrit-scm:
331 refspec: "refs/heads/{branch}"
333 submodule-recursive: true
334 submodule-timeout: "{submodule-timeout}"
335 submodule-disable: "{submodule-disable}"
336 choosing-strategy: default
337 jenkins-ssh-credential: "{jenkins-ssh-credential}"
340 - timed: "{obj:cron}"
342 server-name: "{gerrit-server-name}"
343 trigger-on: "{obj:gerrit_merge_triggers}"
345 - project-compare-type: ANT
346 project-pattern: "{project}"
348 - branch-compare-type: ANT
349 branch-pattern: "**/{branch}"
350 file-paths: "{obj:gerrit_trigger_file_paths}"
353 name: "{project-name}-jenkins-cfg-merge"
354 id: github-jenkins-cfg-merge
355 <<: *lf_jenkins_cfg_merge
358 - lf-infra-properties:
360 build-days-to-keep: 1
362 url: "{github-url}/{github-org}/{project}"
365 - lf-infra-github-scm:
366 url: "{git-clone-url}{github-org}/{project}"
368 branch: "refs/heads/{branch}"
369 submodule-recursive: true
370 submodule-timeout: "{submodule-timeout}"
371 submodule-disable: "{submodule-disable}"
372 choosing-strategy: default
373 jenkins-ssh-credential: "{jenkins-ssh-credential}"
376 - timed: "{obj:cron}"
380 - github-pull-request:
381 trigger-phrase: "^remerge$"
382 only-trigger-phrase: true
383 status-context: "Jenkins CFG Merge"
388 white-list: "{obj:github_pr_whitelist}"
389 admin-list: "{obj:github_pr_admin_list}"
390 included-regions: "{obj:github_included_regions}"
391 white-list-target-branches:
394 ###########################################
395 # Jenkins Configuration Management Verify #
396 ###########################################
398 - lf_jenkins_configuration: &lf_jenkins_cfg_verify
399 name: lf-jenkins-cfg-verify
401 ######################
402 # Default parameters #
403 ######################
406 build-days-to-keep: 7
408 git-url: "$GIT_URL/$GERRIT_PROJECT"
409 github-url: "https://github.com"
410 submodule-timeout: 10
411 submodule-disable: false
413 gerrit_verify_triggers:
414 - patchset-created-event:
416 exclude-trivial-rebase: false
417 exclude-no-code-change: false
418 - draft-published-event
419 - comment-added-contains-event:
420 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
422 gerrit_trigger_file_paths:
423 - compare-type: REG_EXP
424 pattern: 'jenkins-config\/.*'
426 # github_included_regions MUST match gerrit_trigger_file_paths
427 github_included_regions:
428 - 'jenkins-config\/.*'
430 #####################
431 # Job Configuration #
432 #####################
434 project-type: freestyle
437 disabled: "{disable-job}"
440 - lf-infra-properties:
442 build-days-to-keep: 1
445 - lf-infra-parameters:
453 jenkins-ssh-credential: "{jenkins-ssh-credential}"
454 - config-file-provider:
455 # Listed after to override openstack-infra-wrappers clouds.yaml
458 - file-id: clouds-yaml
459 target: "$HOME/.config/openstack/clouds.yaml"
461 target: "$HOME/.npmrc"
463 target: "$HOME/.config/pip/pip.conf"
467 - shell: !include-raw-escape: ../shell/jenkins-verify-images.sh
473 name: "{project-name}-jenkins-cfg-verify"
474 id: gerrit-jenkins-cfg-verify
475 <<: *lf_jenkins_cfg_verify
478 - lf-infra-gerrit-scm:
480 refspec: "$GERRIT_REFSPEC"
481 branch: "$GERRIT_BRANCH"
482 submodule-recursive: true
483 submodule-timeout: "{submodule-timeout}"
484 submodule-disable: "{submodule-disable}"
485 choosing-strategy: gerrit
486 jenkins-ssh-credential: "{jenkins-ssh-credential}"
490 server-name: "{gerrit-server-name}"
491 trigger-on: "{obj:gerrit_verify_triggers}"
493 - project-compare-type: ANT
494 project-pattern: "{project}"
496 - branch-compare-type: ANT
497 branch-pattern: "**/{branch}"
498 file-paths: "{obj:gerrit_trigger_file_paths}"
501 name: "{project-name}-jenkins-cfg-verify"
502 id: github-jenkins-cfg-verify
503 <<: *lf_jenkins_cfg_verify
507 url: "{github-url}/{github-org}/{project}"
510 - lf-infra-github-scm:
511 url: "{git-clone-url}{github-org}/{project}"
512 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
514 submodule-recursive: true
515 submodule-timeout: "{submodule-timeout}"
516 submodule-disable: "{submodule-disable}"
517 choosing-strategy: default
518 jenkins-ssh-credential: "{jenkins-ssh-credential}"
521 - github-pull-request:
522 trigger-phrase: "^(recheck|reverify)$"
523 only-trigger-phrase: false
524 status-context: "Jenkins CFG Verify"
527 included-regions: "{obj:github_included_regions}"
528 white-list-target-branches:
531 ###########################
532 # JENKINS SANDBOX CLEANUP #
533 ###########################
535 - lf_jenkins_sandbox_cleanup: &lf_jenkins_sandbox_cleanup
536 name: lf-jenkins-sandbox-cleanup
538 ######################
539 # Default parameters #
540 ######################
543 # Run every Saturday at 08:00 UTC
547 #####################
548 # Job Configuration #
549 #####################
551 project-type: freestyle
554 disabled: "{disable-job}"
557 - lf-infra-jjb-parameters:
558 jjb-cache: "{jjb-cache}"
559 jjb-version: "{jjb-version}"
562 - timed: "{obj:cron}"
566 - shell: !include-raw-escape:
567 - ../shell/jenkins-sandbox-cleanup.sh
570 name: "{project-name}-jenkins-sandbox-cleanup"
571 id: gerrit-jenkins-sandbox-cleanup
573 # yamllint disable-line rule:key-duplicates
574 <<: *lf_jenkins_sandbox_cleanup
577 name: "{project-name}-jenkins-sandbox-cleanup"
578 id: github-jenkins-sandbox-cleanup
580 # yamllint disable-line rule:key-duplicates
581 <<: *lf_jenkins_sandbox_cleanup
587 - lf_jjb_deploy_job: &lf_jjb_deploy_job
588 name: lf-jjb-deploy-job
590 ######################
591 # Default parameters #
592 ######################
596 # jjb-deploy should always clone $PROJECT regardless of what
597 # $GERRIT_PROJECT triggered the job.
598 git-url: "$GIT_URL/$PROJECT"
599 github-url: "https://github.com"
601 submodule-timeout: 10
602 submodule-disable: false
603 gerrit_jjb_deploy_job_triggers:
604 - comment-added-contains-event:
605 comment-contains-value: '^Patch Set\s+\d+:\s+(jjb-deploy[:]* (?!\*+$).+$)'
607 #####################
608 # Job Configuration #
609 #####################
611 project-type: freestyle
614 disabled: "{disable-job}"
617 - lf-infra-properties:
619 build-days-to-keep: 1
622 - lf-infra-parameters:
630 jenkins-ssh-credential: "{jenkins-ssh-credential}"
634 pip-packages: jenkins-job-builder
636 - shell: !include-raw-escape: ../shell/jjb-deploy-job.sh
642 name: "{project-name}-jjb-deploy-job"
643 id: gerrit-jjb-deploy-job
644 <<: *lf_jjb_deploy_job
647 - lf-infra-gerrit-scm:
649 refspec: "refs/heads/{branch}"
651 submodule-recursive: true
652 submodule-timeout: "{submodule-timeout}"
653 submodule-disable: "{submodule-disable}"
654 choosing-strategy: default
655 jenkins-ssh-credential: "{jenkins-ssh-credential}"
659 server-name: "{gerrit-server-name}"
660 trigger-on: "{obj:gerrit_jjb_deploy_job_triggers}"
662 - project-compare-type: ANT
663 project-pattern: "**"
665 - branch-compare-type: ANT
674 name: "{project-name}-jjb-deploy-job"
675 id: github-jjb-deploy-job
676 <<: *lf_jjb_deploy_job
679 - lf-infra-properties:
681 build-days-to-keep: 1
683 url: "{github-url}/{github-org}/{project}"
686 - lf-infra-github-scm:
687 url: "{git-clone-url}{github-org}/{project}"
688 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
690 submodule-recursive: true
691 submodule-timeout: "{submodule-timeout}"
692 submodule-disable: "{submodule-disable}"
693 choosing-strategy: default
694 jenkins-ssh-credential: "{jenkins-ssh-credential}"
697 - github-pull-request:
698 trigger-phrase: '^jjb-deploy (?!\*+$).+$'
699 only-trigger-phrase: true
700 status-context: "JJB Deploy Job"
703 white-list-target-branches:
710 - lf_jjb_merge: &lf_jjb_merge
713 ######################
714 # Default parameters #
715 ######################
719 gerrit_merge_triggers:
720 - change-merged-event
721 - comment-added-contains-event:
722 comment-contains-value: '^Patch Set\s+\d+:\s+remerge\s*$'
724 #####################
725 # Job Configuration #
726 #####################
732 properties-content: JJB_WORKERS={jjb-workers}
733 - shell: !include-raw-escape:
734 - ../shell/jjb-merge-job.sh
737 name: "{project-name}-jjb-merge"
740 # yamllint disable-line rule:key-duplicates
743 git-url: "$GIT_URL/$GERRIT_PROJECT"
746 - lf-infra-gerrit-scm:
750 submodule-recursive: "{submodule-recursive}"
751 submodule-timeout: "{submodule-timeout}"
752 submodule-disable: "{submodule-disable}"
753 choosing-strategy: default
754 jenkins-ssh-credential: "{jenkins-ssh-credential}"
758 server-name: "{gerrit-server-name}"
759 trigger-on: "{obj:gerrit_merge_triggers}"
761 - project-compare-type: ANT
762 project-pattern: "{project}"
764 - branch-compare-type: ANT
765 branch-pattern: "**/{branch}"
766 file-paths: "{obj:gerrit_trigger_file_paths}"
769 name: "{project-name}-jjb-merge"
772 # yamllint disable-line rule:key-duplicates
775 #####################
776 # Job Configuration #
777 #####################
780 - lf-infra-properties:
782 build-days-to-keep: 7
784 url: "{github-url}/{github-org}/{project}"
787 - lf-infra-github-scm:
788 url: "{git-clone-url}{github-org}/{project}"
790 branch: "refs/heads/{branch}"
791 submodule-recursive: "{submodule-recursive}"
792 submodule-timeout: "{submodule-timeout}"
793 submodule-disable: "{submodule-disable}"
794 choosing-strategy: default
795 jenkins-ssh-credential: "{jenkins-ssh-credential}"
801 - github-pull-request:
802 trigger-phrase: "^remerge$"
803 only-trigger-phrase: true
804 status-context: "JJB Merge"
809 white-list: "{obj:github_pr_whitelist}"
810 admin-list: "{obj:github_pr_admin_list}"
811 included-regions: "{obj:github_included_regions}"
812 white-list-target-branches:
819 - lf_jjb_verify: &lf_jjb_verify
822 ######################
823 # Default parameters #
824 ######################
826 build-concurrent: true
828 gerrit_verify_triggers:
829 - patchset-created-event:
831 exclude-trivial-rebase: false
832 exclude-no-code-change: false
833 - draft-published-event
834 - comment-added-contains-event:
835 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
837 #####################
838 # Job Configuration #
839 #####################
841 concurrent: "{build-concurrent}"
846 - shell: !include-raw-escape:
847 - ../shell/jjb-verify-job.sh
848 - lf-infra-gpg-verify-git-signature
851 name: "{project-name}-jjb-verify"
852 id: gerrit-jjb-verify
854 # yamllint disable-line rule:key-duplicates
857 ######################
858 # Default parameters #
859 ######################
861 git-url: "$GIT_URL/$GERRIT_PROJECT"
863 #####################
864 # Job Configuration #
865 #####################
868 - lf-infra-gerrit-scm:
870 refspec: "$GERRIT_REFSPEC"
871 branch: "$GERRIT_BRANCH"
872 submodule-recursive: "{submodule-recursive}"
873 submodule-timeout: "{submodule-timeout}"
874 submodule-disable: "{submodule-disable}"
875 choosing-strategy: gerrit
876 jenkins-ssh-credential: "{jenkins-ssh-credential}"
880 server-name: "{gerrit-server-name}"
881 trigger-on: "{obj:gerrit_verify_triggers}"
883 - project-compare-type: ANT
884 project-pattern: "{project}"
886 - branch-compare-type: ANT
887 branch-pattern: "**/{branch}"
888 file-paths: "{obj:gerrit_trigger_file_paths}"
891 name: "{project-name}-jjb-verify"
892 id: github-jjb-verify
894 # yamllint disable-line rule:key-duplicates
897 #####################
898 # Job Configuration #
899 #####################
902 - lf-infra-properties:
904 build-days-to-keep: 7
906 url: "{github-url}/{github-org}/{project}"
909 - lf-infra-github-scm:
910 url: "{git-clone-url}{github-org}/{project}"
911 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
913 submodule-recursive: "{submodule-recursive}"
914 submodule-timeout: "{submodule-timeout}"
915 submodule-disable: "{submodule-disable}"
916 choosing-strategy: default
917 jenkins-ssh-credential: "{jenkins-ssh-credential}"
920 - github-pull-request:
921 trigger-phrase: "^(recheck|reverify)$"
922 only-trigger-phrase: false
923 status-context: "JJB Verify"
926 included-regions: "{obj:github_included_regions}"
927 white-list-target-branches:
930 ############################
931 # JJB Verify Upstream GJJB #
932 ############################
934 - lf_jjb_verify: &lf_jjb_verify_upstream_gjjb
935 name: lf-jjb-verify-upstream-gjjb
937 #####################
938 # Job Configuration #
939 #####################
946 git fetch https://gerrit.linuxfoundation.org/infra/releng/global-jjb $GERRIT_REFSPEC
947 git cherry-pick FETCH_HEAD
949 - shell: !include-raw-escape:
950 - ../shell/jjb-verify-job.sh
951 - lf-infra-gpg-verify-git-signature
954 name: "{project-name}-jjb-verify-upstream-gjjb"
955 id: gerrit-jjb-verify-upstream-gjjb
957 # yamllint disable-line rule:key-duplicates
958 <<: *lf_jjb_verify_upstream_gjjb
960 ######################
961 # Default parameters #
962 ######################
964 git-url: "$GIT_URL/$PROJECT"
965 submodule-timeout: 10
966 submodule-disable: false
968 #####################
969 # Job Configuration #
970 #####################
973 - lf-infra-gerrit-scm:
977 submodule-recursive: true
978 submodule-timeout: "{submodule-timeout}"
979 submodule-disable: "{submodule-disable}"
980 choosing-strategy: default
981 jenkins-ssh-credential: "{jenkins-ssh-credential}"
985 server-name: "LinuxFoundation"
987 - patchset-created-event:
989 exclude-trivial-rebase: false
990 exclude-no-code-change: false
991 - draft-published-event
992 - comment-added-contains-event:
993 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
995 - project-compare-type: ANT
996 project-pattern: "releng/global-jjb"
998 - branch-compare-type: ANT
999 branch-pattern: "**/master"
1000 override-votes: true
1001 gerrit-build-failed-codereview-value: -1
1002 gerrit-build-failed-verified-value: 0
1003 gerrit-build-successful-codereview-value: 1
1004 gerrit-build-successful-verified-value: 0
1010 - lf_license_check: &lf_license_check
1011 name: lf-license-check
1013 ######################
1014 # Default parameters #
1015 ######################
1018 build-days-to-keep: 7
1027 git-url: "$GIT_URL/$PROJECT"
1028 github-url: "https://github.com"
1030 license-exclude-paths: ""
1031 licenses-allowed: Apache-2.0,EPL-1.0,MIT
1032 project-pattern: "**"
1035 submodule-timeout: 10
1036 submodule-disable: false
1038 #####################
1039 # Job Configuration #
1040 #####################
1042 project-type: freestyle
1043 node: "{build-node}"
1045 disabled: "{disable-job}"
1048 - lf-infra-properties:
1049 build-days-to-keep: "{build-days-to-keep}"
1052 - lf-infra-parameters:
1053 project: "{project}"
1058 - lf-infra-wrappers:
1059 build-timeout: "{build-timeout}"
1060 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1064 file-patterns: "{file-patterns}"
1065 spdx-disable: "{spdx-disable}"
1066 lhc-version: "{lhc-version}"
1067 license-exclude-paths: "{license-exclude-paths}"
1068 licenses-allowed: "{licenses-allowed}"
1074 name: "{project-name}-license-check"
1075 id: gerrit-license-check
1076 <<: *lf_license_check
1078 git-url: "$GIT_URL/$GERRIT_PROJECT"
1081 - lf-infra-gerrit-scm:
1082 git-url: "{git-url}"
1083 refspec: "$GERRIT_REFSPEC"
1084 branch: "$GERRIT_BRANCH"
1085 # Submodules are out of the project's control
1086 submodule-recursive: false
1087 submodule-timeout: "{submodule-timeout}"
1088 submodule-disable: "{submodule-disable}"
1089 choosing-strategy: gerrit
1090 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1094 server-name: "{gerrit-server-name}"
1095 # Trigger should not be overridable as we want to always run
1097 - patchset-created-event:
1098 exclude-drafts: false
1099 exclude-trivial-rebase: false
1100 exclude-no-code-change: false
1101 - draft-published-event
1102 - comment-added-contains-event:
1103 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
1105 - project-compare-type: ANT
1106 project-pattern: "{project-pattern}"
1108 - branch-compare-type: ANT
1109 branch-pattern: "**"
1112 name: "{project-name}-license-check"
1113 id: github-license-check
1114 <<: *lf_license_check
1117 - lf-infra-properties:
1118 build-days-to-keep: "{build-days-to-keep}"
1120 url: "{github-url}/{github-org}/{project}"
1123 - lf-infra-github-scm:
1124 url: "{git-clone-url}{github-org}/{project}"
1125 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
1127 # Submodules are out of the project's control
1128 submodule-recursive: false
1129 submodule-timeout: "{submodule-timeout}"
1130 submodule-disable: "{submodule-disable}"
1131 choosing-strategy: default
1132 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1135 - github-pull-request:
1136 trigger-phrase: "^recheck$"
1137 only-trigger-phrase: false
1138 status-context: "License Check"
1141 white-list-target-branches:
1144 ####################
1145 # Info YAML Verify #
1146 ####################
1148 - lf_info_yaml_verify: &lf_info_yaml_verify
1149 name: lf-info-yaml-verify
1151 ######################
1152 # Default parameters #
1153 ######################
1155 gerrit_verify_triggers:
1156 - patchset-created-event:
1157 exclude-drafts: true
1158 exclude-trivial-rebase: false
1159 exclude-no-code-change: false
1160 - draft-published-event
1161 - comment-added-contains-event:
1162 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
1164 #####################
1165 # Job Configuration #
1166 #####################
1171 - shell: !include-raw-escape:
1172 - ../shell/git-validate-info-yaml.sh
1173 - ../shell/info-file-validate.sh
1176 name: "{project-name}-info-yaml-verify"
1177 id: gerrit-info-yaml-verify
1179 # yamllint disable-line rule:key-duplicates
1180 <<: *lf_info_yaml_verify
1182 git-url: "$GIT_URL/$GERRIT_PROJECT"
1185 - lf-infra-gerrit-scm:
1186 git-url: "{git-url}"
1187 refspec: "$GERRIT_REFSPEC"
1188 branch: "$GERRIT_BRANCH"
1189 submodule-recursive: "{submodule-recursive}"
1190 submodule-timeout: "{submodule-timeout}"
1191 submodule-disable: "{submodule-disable}"
1192 choosing-strategy: gerrit
1193 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1197 server-name: "{gerrit-server-name}"
1198 trigger-on: "{obj:gerrit_verify_triggers}"
1200 - project-compare-type: ANT
1201 project-pattern: "{project}"
1203 - branch-compare-type: ANT
1204 branch-pattern: "**/{branch}"
1206 - compare-type: REG_EXP
1207 pattern: "INFO.yaml"
1210 name: "{project-name}-info-yaml-verify"
1211 id: github-info-yaml-verify
1213 # yamllint disable-line rule:key-duplicates
1214 <<: *lf_info_yaml_verify
1216 github-url: "https://github.com"
1219 url: "{github-url}/{github-org}/{project}"
1222 - lf-infra-github-scm:
1223 url: "{git-clone-url}{github-org}/{project}"
1224 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
1226 submodule-recursive: "{submodule-recursive}"
1227 submodule-timeout: "{submodule-timeout}"
1228 submodule-disable: "{submodule-disable}"
1229 choosing-strategy: default
1230 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1233 - github-pull-request:
1234 trigger-phrase: "^(recheck|reverify)$"
1235 only-trigger-phrase: false
1236 status-context: "INFO File Verify"
1239 # included-regions MUST match gerrit file-paths
1240 included-regions: "INFO.yaml"
1241 white-list-target-branches:
1248 - lf_openstack_cron: &lf_openstack_cron
1249 name: lf-openstack-cron
1251 ######################
1252 # Default parameters #
1253 ######################
1256 build-days-to-keep: 7
1260 git-url: "$GIT_URL/$PROJECT"
1261 github-url: "https://github.com"
1262 openstack-cloud: vex
1263 openstack-image-cleanup: true
1264 openstack-image-cleanup-age: 30
1265 openstack-image-protect: true
1266 openstack-port-cleanup: true
1267 openstack-server-cleanup: true
1268 openstack-stack-cleanup: true
1269 openstack-volume-cleanup: true
1271 submodule-timeout: 10
1272 submodule-disable: false
1274 #####################
1275 # Job Configuration #
1276 #####################
1278 project-type: freestyle
1279 node: "{build-node}"
1281 disabled: "{disable-job}"
1284 - lf-infra-properties:
1285 build-days-to-keep: "{build-days-to-keep}"
1288 - lf-infra-parameters:
1289 project: "{project}"
1294 default: "{jenkins-urls}"
1296 Space separated list of Jenkins URLs to check for active builds.
1299 - lf-infra-wrappers:
1300 build-timeout: "{build-timeout}"
1301 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1302 # Listed after to override openstack-infra-wrappers clouds.yaml definition
1303 - config-file-provider:
1305 - file-id: clouds-yaml
1306 target: "$HOME/.config/openstack/clouds.yaml"
1308 target: "$HOME/.npmrc"
1310 target: "$HOME/.config/pip/pip.conf"
1313 - timed: "{obj:cron}"
1316 - lf-infra-pre-build
1318 properties-content: OS_CLOUD={openstack-cloud}
1321 condition-kind: boolean-expression
1322 condition-expression: "{openstack-stack-cleanup}"
1324 - shell: !include-raw-escape: ../shell/openstack-cleanup-orphaned-stacks.sh
1327 condition-kind: boolean-expression
1328 condition-expression: "{openstack-server-cleanup}"
1330 - shell: !include-raw-escape: ../shell/openstack-cleanup-orphaned-servers.sh
1333 condition-kind: boolean-expression
1334 condition-expression: "{openstack-port-cleanup}"
1336 - shell: !include-raw-escape: ../shell/openstack-cleanup-orphaned-ports.sh
1339 condition-kind: boolean-expression
1340 condition-expression: "{openstack-volume-cleanup}"
1342 - shell: !include-raw-escape: ../shell/openstack-cleanup-orphaned-volumes.sh
1345 condition-kind: boolean-expression
1346 condition-expression: "{openstack-image-protect}"
1348 - shell: !include-raw-escape: ../shell/openstack-protect-in-use-images.sh
1350 condition-kind: boolean-expression
1351 condition-expression: "{openstack-image-cleanup}"
1354 properties-content: OS_IMAGE_CLEANUP_AGE={openstack-image-cleanup-age}
1355 - shell: !include-raw-escape: ../shell/openstack-cleanup-old-images.sh
1361 name: "{project-name}-openstack-cron"
1362 id: gerrit-openstack-cron
1363 <<: *lf_openstack_cron
1366 - lf-infra-gerrit-scm:
1367 git-url: "{git-url}"
1368 refspec: "refs/heads/{branch}"
1370 submodule-recursive: true
1371 submodule-timeout: "{submodule-timeout}"
1372 submodule-disable: "{submodule-disable}"
1373 choosing-strategy: default
1374 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1377 name: "{project-name}-openstack-cron"
1378 id: github-openstack-cron
1379 <<: *lf_openstack_cron
1382 - lf-infra-github-scm:
1383 url: "{git-clone-url}{github-org}/{project}"
1385 branch: "refs/heads/{branch}"
1386 submodule-recursive: true
1387 submodule-timeout: "{submodule-timeout}"
1388 submodule-disable: "{submodule-disable}"
1389 choosing-strategy: default
1390 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1396 - lf_packer_merge: &lf_packer_merge
1397 name: lf-packer-merge
1399 ######################
1400 # Default parameters #
1401 ######################
1404 openstack-cloud: vex
1405 update-cloud-image: false
1407 #####################
1408 # Job Configuration #
1409 #####################
1412 - lf-infra-parameters:
1413 project: "{project}"
1416 - lf-packer-parameters:
1417 packer-version: "{packer-version}"
1419 name: UPDATE_CLOUD_IMAGE
1420 default: "{update-cloud-image}"
1421 description: "Update new built image on the cloud."
1424 - lf-infra-packer-build:
1425 openstack: "{openstack}"
1426 openstack-cloud: "{openstack-cloud}"
1427 packer-cloud-settings: "{packer-cloud-settings}"
1428 packer-version: "{packer-version}"
1429 platform: "{platforms}"
1430 template: "{templates}"
1431 update-cloud-image: "{update-cloud-image}"
1432 - description-setter:
1433 regexp: '(\s+.*)(ZZCI\s+.*\d+-\d+\.\d+)'
1434 description: 'Image: \2'
1436 # - project: '{project-name}-openstack-update-cloud-image'
1438 # predefined-parameters: |
1439 # GERRIT_BRANCH=$GERRIT_BRANCH
1440 # GERRIT_PROJECT=$GERRIT_PROJECT
1441 # GERRIT_REFSPEC=$GERRIT_REFSPEC
1442 # NEW_IMAGE_NAME=$NEW_IMAGE_NAME
1443 # property-file: variables.jenkins-trigger
1444 # property-file-fail-on-missing: true
1448 - trigger-parameterized-builds:
1449 - project: "{project-name}-openstack-update-cloud-image"
1450 condition: UNSTABLE_OR_BETTER
1451 predefined-parameters: |
1452 NEW_IMAGE_NAME=$NEW_IMAGE_NAME
1453 property-file: variables.jenkins-trigger
1454 fail-on-missing: true
1457 name: "{project-name}-packer-merge-{platforms}-{templates}"
1458 id: gerrit-packer-merge
1459 <<: *lf_packer_common
1460 # yamllint disable-line rule:key-duplicates
1461 <<: *lf_packer_merge
1463 ######################
1464 # Default parameters #
1465 ######################
1467 git-url: "$GIT_URL/$GERRIT_PROJECT"
1469 gerrit_merge_triggers:
1470 - change-merged-event
1471 - comment-added-contains-event:
1472 comment-contains-value: '^Patch Set\s+\d+:\s+remerge\s*$'
1474 #####################
1475 # Job Configuration #
1476 #####################
1479 - lf-infra-gerrit-scm:
1480 git-url: "{git-url}"
1481 refspec: "$GERRIT_REFSPEC"
1482 branch: "$GERRIT_BRANCH"
1483 submodule-recursive: "{submodule-recursive}"
1484 submodule-timeout: "{submodule-timeout}"
1485 submodule-disable: "{submodule-disable}"
1486 choosing-strategy: default
1487 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1490 - timed: "{obj:cron}"
1492 server-name: "{gerrit-server-name}"
1493 trigger-on: "{obj:gerrit_merge_triggers}"
1495 - project-compare-type: ANT
1496 project-pattern: "{project}"
1498 - branch-compare-type: ANT
1499 branch-pattern: "**/{branch}"
1501 - compare-type: REG_EXP
1502 pattern: 'packer\/provision\/.*\.sh'
1503 - compare-type: REG_EXP
1504 pattern: 'packer\/provision\/.*\.bat'
1505 - compare-type: REG_EXP
1506 pattern: 'packer\/provision\/.*\.ps1'
1507 - compare-type: REG_EXP
1508 pattern: 'packer\/provision\/{templates}\.yaml'
1509 - compare-type: REG_EXP
1510 pattern: 'packer\/provision\/local-{templates}\.yaml'
1511 - compare-type: REG_EXP
1512 pattern: 'packer\/templates\/{templates}\.json'
1513 - compare-type: REG_EXP
1514 pattern: 'packer\/vars\/{platforms}\.json'
1517 name: "{project-name}-packer-merge-{platforms}-{templates}"
1518 id: github-packer-merge
1519 <<: *lf_packer_common
1520 # yamllint disable-line rule:key-duplicates
1521 <<: *lf_packer_merge
1523 #####################
1524 # Job Configuration #
1525 #####################
1528 - lf-infra-properties:
1529 project: "{project}"
1530 build-days-to-keep: 7
1532 url: "{github-url}/{github-org}/{project}"
1535 - lf-infra-github-scm:
1536 url: "{git-clone-url}{github-org}/{project}"
1538 +refs/heads/*:refs/remotes/origin/*
1539 +refs/pull/*:refs/remotes/origin/pr/*
1540 branch: "$GERRIT_REFSPEC"
1541 submodule-recursive: "{submodule-recursive}"
1542 submodule-timeout: "{submodule-timeout}"
1543 submodule-disable: "{submodule-disable}"
1544 choosing-strategy: default
1545 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1548 - timed: "{obj:cron}"
1553 - github-pull-request:
1554 trigger-phrase: "^remerge$"
1555 only-trigger-phrase: true
1556 status-context: "Packer {platforms}-{templates} Merge"
1561 white-list: "{obj:github_pr_whitelist}"
1562 admin-list: "{obj:github_pr_admin_list}"
1563 # included-regions MUST match Gerrit Trigger file-paths
1565 - 'packer\/provision\/.*\.sh'
1566 - 'packer\/provision\/.*\.bat'
1567 - 'packer\/provision\/.*\.ps1'
1568 - 'packer\/provision\/{templates}\.yaml'
1569 - 'packer\/provision\/local-{templates}\.yaml'
1570 - 'packer\/templates\/{templates}\.json'
1571 - 'packer\/vars\/{platforms}\.json'
1572 white-list-target-branches:
1579 - lf_packer_verify: &lf_packer_verify
1580 name: lf-packer-verify
1582 ######################
1583 # Default parameters #
1584 ######################
1588 openstack-cloud: vex
1590 gerrit_verify_triggers:
1591 - patchset-created-event:
1592 exclude-drafts: true
1593 exclude-trivial-rebase: false
1594 exclude-no-code-change: false
1595 - draft-published-event
1596 - comment-added-contains-event:
1597 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
1599 gerrit_trigger_file_paths:
1600 - compare-type: REG_EXP
1601 pattern: 'packer\/.*'
1603 # github_included_regions MUST match gerrit_trigger_file_paths
1604 github_included_regions:
1607 #####################
1608 # Job Configuration #
1609 #####################
1614 - lf-infra-packer-validate:
1615 openstack: "{openstack}"
1616 openstack-cloud: "{openstack-cloud}"
1617 packer-cloud-settings: "{packer-cloud-settings}"
1618 packer-version: "{packer-version}"
1621 name: "{project-name}-packer-verify"
1622 id: gerrit-packer-verify
1623 <<: *lf_packer_common
1624 # yamllint disable-line rule:key-duplicates
1625 <<: *lf_packer_verify
1627 ######################
1628 # Default parameters #
1629 ######################
1631 git-url: "$GIT_URL/$GERRIT_PROJECT"
1633 #####################
1634 # Job Configuration #
1635 #####################
1638 - lf-infra-gerrit-scm:
1639 git-url: "{git-url}"
1640 refspec: "$GERRIT_REFSPEC"
1641 branch: "$GERRIT_BRANCH"
1642 submodule-recursive: "{submodule-recursive}"
1643 submodule-timeout: "{submodule-timeout}"
1644 submodule-disable: "{submodule-disable}"
1645 choosing-strategy: gerrit
1646 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1650 server-name: "{gerrit-server-name}"
1651 trigger-on: "{obj:gerrit_verify_triggers}"
1653 - project-compare-type: ANT
1654 project-pattern: "{project}"
1656 - branch-compare-type: ANT
1657 branch-pattern: "**/{branch}"
1658 file-paths: "{obj:gerrit_trigger_file_paths}"
1661 name: "{project-name}-packer-verify"
1662 id: github-packer-verify
1663 <<: *lf_packer_common
1664 # yamllint disable-line rule:key-duplicates
1665 <<: *lf_packer_verify
1667 #####################
1668 # Job Configuration #
1669 #####################
1672 - lf-infra-properties:
1673 project: "{project}"
1674 build-days-to-keep: 7
1676 url: "{github-url}/{github-org}/{project}"
1679 - lf-infra-github-scm:
1680 url: "{git-clone-url}{github-org}/{project}"
1681 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
1683 submodule-recursive: "{submodule-recursive}"
1684 submodule-timeout: "{submodule-timeout}"
1685 submodule-disable: "{submodule-disable}"
1686 choosing-strategy: default
1687 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1690 - github-pull-request:
1691 trigger-phrase: "^(recheck|reverify)$"
1692 only-trigger-phrase: false
1693 status-context: "Packer Verify"
1696 included-regions: "{obj:github_included_regions}"
1697 white-list-target-branches:
1700 ################################
1701 # Openstack Update Cloud Image #
1702 ################################
1704 - lf_openstack_cron: &lf_openstack_update_cloud_image
1705 name: lf-openstack-update-cloud-image
1707 ######################
1708 # Default parameters #
1709 ######################
1712 build-days-to-keep: 7
1716 git-url: "$GIT_URL/$PROJECT"
1717 github-url: "https://github.com"
1718 new-image-name: "all"
1719 openstack-cloud: vex
1721 submodule-timeout: 10
1722 submodule-disable: false
1723 update-cloud-image: false
1725 #####################
1726 # Job Configuration #
1727 #####################
1729 project-type: freestyle
1730 node: "{build-node}"
1732 disabled: "{disable-job}"
1735 - lf-infra-properties:
1736 build-days-to-keep: "{build-days-to-keep}"
1739 - lf-infra-parameters:
1740 project: "{project}"
1744 name: NEW_IMAGE_NAME
1745 default: "{new-image-name}"
1746 description: "Name of cloud image to update in Jenkins"
1749 - lf-infra-wrappers:
1750 build-timeout: "{build-timeout}"
1751 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1752 # Listed after to override openstack-infra-wrappers clouds.yaml definition
1753 - config-file-provider:
1755 - file-id: clouds-yaml
1756 target: "$HOME/.config/openstack/clouds.yaml"
1758 target: "$HOME/.npmrc"
1760 target: "$HOME/.config/pip/pip.conf"
1763 - lf-infra-pre-build
1765 properties-content: |
1766 OS_CLOUD={openstack-cloud}
1769 echo "Extract the image type for commit message"
1770 # echo IMAGE_TYPE=${{NEW_IMAGE_NAME% -*}} >> image-type.txt
1771 IMAGE_TYPE=$(echo ${{NEW_IMAGE_NAME}} | tr -d "\'\"\ " | awk -F- '{{ print $2 " " $3 " " $4 }}')
1772 echo IMAGE_TYPE=${{IMAGE_TYPE}} >> image-type.txt
1775 properties-file: "image-type.txt"
1776 - lf-infra-update-packer-images
1777 - lf-infra-push-gerrit-patch:
1778 project: "{project}"
1779 gerrit-user: "{gerrit-user}"
1780 gerrit-host: "{gerrit-host}"
1781 gerrit-topic: "{gerrit-topic}"
1782 gerrit-commit-message: "Update cloud image $IMAGE_TYPE"
1783 reviewers-email: "{reviewers-email}"
1789 name: "{project-name}-openstack-update-cloud-image"
1790 id: gerrit-openstack-update-cloud-image
1791 <<: *lf_openstack_update_cloud_image
1793 ######################
1794 # Default parameters #
1795 ######################
1797 git-url: "$GIT_URL/$GERRIT_PROJECT"
1799 #####################
1800 # Job Configuration #
1801 #####################
1804 - lf-infra-gerrit-scm:
1805 git-url: "{git-url}"
1806 refspec: "$GERRIT_REFSPEC"
1807 branch: "$GERRIT_BRANCH"
1808 submodule-recursive: false
1809 submodule-timeout: "{submodule-timeout}"
1810 submodule-disable: "{submodule-disable}"
1811 choosing-strategy: gerrit
1812 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1815 - timed: "{obj:cron}"
1821 - lf_puppet_verify: &lf_puppet_verify
1822 name: lf-puppet-verify
1824 ######################
1825 # Default parameters #
1826 ######################
1829 build-days-to-keep: 7
1832 git-url: "$GIT_URL/$GERRIT_PROJECT"
1833 github-url: "https://github.com"
1836 puppet-lint-version: 2.3.6
1838 submodule-recursive: true
1839 submodule-timeout: 10
1840 submodule-disable: false
1842 gerrit_trigger_file_paths:
1843 - compare-type: REG_EXP
1846 # github_included_regions MUST match gerrit_trigger_file_paths
1847 github_included_regions:
1850 #####################
1851 # Job Configuration #
1852 #####################
1854 project-type: freestyle
1855 node: "{build-node}"
1857 disabled: "{disable-job}"
1860 - lf-infra-properties:
1861 build-days-to-keep: "{build-days-to-keep}"
1864 - lf-infra-parameters:
1865 project: "{project}"
1868 - lf-puppet-parameters:
1869 puppet-lint-version: "{puppet-lint-version}"
1872 - lf-infra-wrappers:
1873 build-timeout: "{build-timeout}"
1874 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1877 - shell: !include-raw-escape: ../shell/puppet-lint.sh
1883 name: "{project-name}-puppet-verify"
1884 id: gerrit-puppet-verify
1885 <<: *lf_puppet_verify
1887 ######################
1888 # Default parameters #
1889 ######################
1891 gerrit_verify_triggers:
1892 - patchset-created-event:
1893 exclude-drafts: true
1894 exclude-trivial-rebase: false
1895 exclude-no-code-change: false
1896 - draft-published-event
1897 - comment-added-contains-event:
1898 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
1900 #####################
1901 # Job Configuration #
1902 #####################
1905 - lf-infra-gerrit-scm:
1906 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1907 git-url: "{git-url}"
1908 refspec: "$GERRIT_REFSPEC"
1909 branch: "$GERRIT_BRANCH"
1910 submodule-recursive: "{submodule-recursive}"
1911 submodule-timeout: "{submodule-timeout}"
1912 submodule-disable: "{submodule-disable}"
1913 choosing-strategy: gerrit
1917 server-name: "{gerrit-server-name}"
1918 trigger-on: "{obj:gerrit_verify_triggers}"
1920 - project-compare-type: ANT
1921 project-pattern: "{project}"
1923 - branch-compare-type: ANT
1924 branch-pattern: "**/{branch}"
1925 file-paths: "{obj:gerrit_trigger_file_paths}"
1928 name: "{project-name}-puppet-verify"
1929 id: github-puppet-verify
1930 <<: *lf_puppet_verify
1932 #####################
1933 # Job Configuration #
1934 #####################
1937 - lf-infra-properties:
1938 project: "{project}"
1939 build-days-to-keep: 7
1941 url: "{github-url}/{github-org}/{project}"
1944 - lf-infra-github-scm:
1945 url: "{git-clone-url}{github-org}/{project}"
1946 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
1948 submodule-recursive: "{submodule-recursive}"
1949 submodule-timeout: "{submodule-timeout}"
1950 submodule-disable: "{submodule-disable}"
1951 choosing-strategy: default
1952 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1955 - github-pull-request:
1956 trigger-phrase: "^(recheck|reverify)$"
1957 only-trigger-phrase: false
1958 status-context: "Puppet Verify"
1961 included-regions: "{obj:github_included_regions}"
1962 white-list-target-branches:
1969 - lf_sonar_common: &lf_sonar_common
1970 name: lf-sonar-common
1972 ######################
1973 # Default parameters #
1974 ######################
1976 archive-artifacts: >
1979 branch: master # Sonar should always be run on master branch
1980 build-days-to-keep: 7
1982 cron: "H H * * *" # run daily
1984 git-url: "$GIT_URL/$PROJECT"
1985 github-url: "https://github.com"
1987 submodule-recursive: true
1988 submodule-timeout: 10
1989 submodule-disable: false
1993 sonar-project-file: "sonar-project.properties"
1994 sonar-properties: ""
1996 sonar-additional-args: ""
1998 gerrit_trigger_file_paths:
1999 - compare-type: REG_EXP
2002 # github_included_regions MUST match gerrit_trigger_file_paths
2003 github_included_regions:
2006 #####################
2007 # Job Configuration #
2008 #####################
2010 project-type: freestyle
2011 node: "{build-node}"
2014 - lf-infra-properties:
2015 build-days-to-keep: "{build-days-to-keep}"
2018 - lf-infra-wrappers:
2019 build-timeout: "{build-timeout}"
2020 jenkins-ssh-credential: "{jenkins-ssh-credential}"
2022 disabled: "{disable-job}"
2025 - lf-infra-parameters:
2026 project: "{project}"
2030 name: ARCHIVE_ARTIFACTS
2031 default: "{archive-artifacts}"
2032 description: Artifacts to archive to the logs server.
2037 - lf_sonar_builders: &lf_sonar_builders
2038 name: lf-sonar-builders
2040 - lf-infra-pre-build
2042 sonar-task: "{sonar-task}"
2043 sonar-project-file: "{sonar-project-file}"
2044 sonar-properties: "{sonar-properties}"
2045 sonar-java-opts: "{sonar-java-opts}"
2046 sonar-additional-args: "{sonar-additional-args}"
2048 - lf_sonar_builders_prescan: &lf_sonar_builders_prescan
2049 name: lf-sonar-builders-prescan
2051 - lf-infra-pre-build
2052 - lf-infra-sonar-with-prescan:
2053 sonar-task: "{sonar-task}"
2054 sonar-project-file: "{sonar-project-file}"
2055 sonar-properties: "{sonar-properties}"
2056 sonar-java-opts: "{sonar-java-opts}"
2057 sonar-additional-args: "{sonar-additional-args}"
2059 - lf_sonar_gerrit_common: &lf_sonar_gerrit_common
2060 name: lf-sonar-gerrit-common
2061 gerrit_sonar_triggers:
2062 - comment-added-contains-event:
2063 comment-contains-value: '^Patch Set\s+\d+:\s+run-sonar\s*$'
2066 - lf-infra-gerrit-scm:
2067 jenkins-ssh-credential: "{jenkins-ssh-credential}"
2068 git-url: "{git-url}"
2069 refspec: $GERRIT_REFSPEC
2070 branch: $GERRIT_BRANCH
2071 submodule-recursive: "{submodule-recursive}"
2072 submodule-timeout: "{submodule-timeout}"
2073 submodule-disable: "{submodule-disable}"
2074 choosing-strategy: default
2077 - timed: "{obj:cron}"
2079 server-name: "{gerrit-server-name}"
2080 trigger-on: "{obj:gerrit_sonar_triggers}"
2082 - project-compare-type: "ANT"
2083 project-pattern: "{project}"
2085 - branch-compare-type: "ANT"
2086 branch-pattern: "**/{branch}"
2087 file-paths: "{obj:gerrit_trigger_file_paths}"
2094 - lf_sonar_github_common: &lf_sonar_github_common
2095 name: lf-sonar-github-common
2097 - lf-infra-properties:
2098 build-days-to-keep: "{build-days-to-keep}"
2100 url: "{github-url}/{github-org}/{project}"
2103 - lf-infra-github-scm:
2104 url: "{git-clone-url}{github-org}/{project}"
2105 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
2107 submodule-recursive: "{submodule-recursive}"
2108 submodule-timeout: "{submodule-timeout}"
2109 submodule-disable: "{submodule-disable}"
2110 choosing-strategy: default
2111 jenkins-ssh-credential: "{jenkins-ssh-credential}"
2114 - github-pull-request:
2115 trigger-phrase: "^run-sonar$"
2116 only-trigger-phrase: false
2117 status-context: "Python Sonar"
2120 white-list-target-branches:
2122 included-regions: "{obj:github_included_regions}"
2125 name: "{project-name}-sonar"
2127 <<: *lf_sonar_common
2128 # yamllint disable-line rule:key-duplicates
2129 <<: *lf_sonar_builders
2130 # yamllint disable-line rule:key-duplicates
2131 <<: *lf_sonar_gerrit_common
2134 name: "{project-name}-sonar"
2136 <<: *lf_sonar_common
2137 # yamllint disable-line rule:key-duplicates
2138 <<: *lf_sonar_builders
2139 # yamllint disable-line rule:key-duplicates
2140 <<: *lf_sonar_github_common
2143 name: "{project-name}-sonar-prescan"
2144 id: gerrit-sonar-prescan
2145 <<: *lf_sonar_common
2146 # yamllint disable-line rule:key-duplicates
2147 <<: *lf_sonar_builders_prescan
2148 # yamllint disable-line rule:key-duplicates
2149 <<: *lf_sonar_gerrit_common
2152 name: "{project-name}-sonar-prescan"
2153 id: github-sonar-prescan
2154 <<: *lf_sonar_common
2155 # yamllint disable-line rule:key-duplicates
2156 <<: *lf_sonar_builders_prescan
2157 # yamllint disable-line rule:key-duplicates
2158 <<: *lf_sonar_github_common