7 name: lf-infra-nexus-iq-python-cli
11 NEXUS_IQ_PROJECT_NAME={nexus-iq-project-name}
12 REQUIREMENTS_FILE={requirements-file}
13 - shell: !include-raw-escape: ../shell/nexus-iq-python-cli.sh
16 name: lf-infra-tox-install
19 properties-content: "PYTHON={python-version}"
20 - shell: !include-raw-escape: ../shell/tox-install.sh
23 name: lf-infra-tox-run
26 properties-content: "PARALLEL={parallel}"
27 - shell: !include-raw-escape: ../shell/tox-run.sh
33 - lf_python_common: &lf_python_common
34 name: lf-python-common
36 ######################
37 # Default parameters #
38 ######################
47 project-type: freestyle
51 - lf-infra-properties:
52 build-days-to-keep: "{build-days-to-keep}"
55 - lf-infra-parameters:
62 build-timeout: "{build-timeout}"
63 jenkins-ssh-credential: "{jenkins-ssh-credential}"
72 - lf_tox_nexus_iq_clm: &lf_tox_nexus_iq_clm
73 name: lf-tox-nexus-iq-clm
75 ######################
76 # Default parameters #
77 ######################
84 git-url: "$GIT_URL/$PROJECT"
85 github-url: "https://github.com"
86 java-version: openjdk11 # Scanner is a jar
87 nexus-iq-cli-version: 1.140.0-01
88 nexus-iq-namespace: "" # Recommend a trailing dash when set. Example: odl-
89 pre-build-script: "# pre-build script goes here"
90 python-version: python3
91 requirements-file: requirements.txt
93 submodule-recursive: true
95 submodule-disable: false
100 # Job Configuration #
101 #####################
103 disabled: "{disable-job}"
106 - lf-infra-parameters:
110 - lf-infra-tox-parameters:
112 tox-envs: "{tox-envs}"
114 name: ARCHIVE_ARTIFACTS
115 default: "{archive-artifacts}"
116 description: Artifacts to archive to the logs server.
118 name: NEXUS_IQ_CLI_VERSION
119 default: "{nexus-iq-cli-version}"
120 description: Nexus IQ CLI jar to download and run.
124 build-timeout: "{build-timeout}"
125 jenkins-ssh-credential: "{jenkins-ssh-credential}"
126 - credentials-binding:
127 - username-password-separated:
128 credential-id: nexus-iq-xc-clm
129 username: NEXUS_IQ_USER
130 password: NEXUS_IQ_PASSWORD
134 - lf-update-java-alternatives:
135 java-version: "{java-version}"
136 - lf-infra-tox-install:
137 python-version: "{python-version}"
138 - shell: "{pre-build-script}"
141 - lf-infra-nexus-iq-python-cli:
142 nexus-iq-project-name: "{nexus-iq-namespace}{project-name}"
143 requirements-file: "{requirements-file}"
146 name: "{project-name}-tox-nexus-iq-clm"
147 id: gerrit-tox-nexus-iq-clm
148 <<: *lf_python_common
149 <<: *lf_tox_nexus_iq_clm
151 ######################
152 # Default parameters #
153 ######################
155 gerrit_nexus_iq_triggers:
156 - comment-added-contains-event:
157 comment-contains-value: '^Patch Set\s+\d+:\s+run-clm\s*$'
159 #####################
160 # Job Configuration #
161 #####################
164 - lf-infra-gerrit-scm:
165 jenkins-ssh-credential: "{jenkins-ssh-credential}"
167 refspec: "$GERRIT_REFSPEC"
168 branch: "$GERRIT_BRANCH"
169 submodule-recursive: "{submodule-recursive}"
170 submodule-timeout: "{submodule-timeout}"
171 submodule-disable: "{submodule-disable}"
172 choosing-strategy: default
175 - timed: "{obj:cron}"
177 server-name: "{gerrit-server-name}"
178 trigger-on: "{obj:gerrit_nexus_iq_triggers}"
180 - project-compare-type: ANT
181 project-pattern: "{project}"
183 - branch-compare-type: ANT
184 branch-pattern: "**/{branch}"
192 name: "{project-name}-tox-nexus-iq"
193 id: github-tox-nexus-iq-clm
194 <<: *lf_python_common
195 <<: *lf_tox_nexus_iq_clm
198 - lf-infra-properties:
199 build-days-to-keep: "{build-days-to-keep}"
201 url: "{github-url}/{github-org}/{project}"
204 - lf-infra-github-scm:
205 url: "{git-clone-url}{github-org}/{project}"
207 branch: "refs/heads/{branch}"
208 submodule-recursive: "{submodule-recursive}"
209 submodule-timeout: "{submodule-timeout}"
210 submodule-disable: "{submodule-disable}"
211 choosing-strategy: default
212 jenkins-ssh-credential: "{jenkins-ssh-credential}"
215 - timed: "{obj:cron}"
216 - github-pull-request:
217 trigger-phrase: "^run-clm$"
218 only-trigger-phrase: false
219 status-context: "CLM"
222 white-list-target-branches:
225 #########################
226 # Python Sonar with CLI #
227 #########################
229 - lf_cli_sonar: &lf_cli_sonar
232 ######################
233 # Default parameters #
234 ######################
236 branch: master # Sonar should always be run on master branch
237 build-days-to-keep: 7
239 cron: "H H * * *" # run daily
241 git-url: "$GIT_URL/$PROJECT"
242 github-url: "https://github.com"
243 # SonarCloud scan using jdk8 will become deprecated by Oct, 2020
244 # Projects not compatible with jdk11 can set java-version to something else
245 java-version: openjdk11
247 pre-build-script: "# pre-build script goes here"
248 python-version: python3
250 sonar-scanner-version: "4.7.0.2747"
251 sonar-scanner-home: "$WORKSPACE/.sonar/sonar-scanner-$SONAR_SCANNER_VERSION-linux"
252 sonar-scanner-opts: "-server"
253 submodule-recursive: true
254 submodule-timeout: 10
255 submodule-disable: false
259 gerrit_trigger_file_paths:
260 - compare-type: REG_EXP
263 # github_included_regions MUST match gerrit_trigger_file_paths
264 github_included_regions:
267 #####################
268 # Job Configuration #
269 #####################
271 disabled: "{disable-job}"
274 - lf-infra-parameters:
278 - lf-infra-sonar-cli-parameters:
280 tox-envs: "{tox-envs}"
281 sonar-scanner-version: "{sonar-scanner-version}"
282 sonar-scanner-home: "{sonar-scanner-home}"
283 sonar-scanner-opts: "{sonar-scanner-opts}"
285 name: ARCHIVE_ARTIFACTS
286 default: "{archive-artifacts}"
287 description: Artifacts to archive to the logs server.
289 - credentials-binding:
291 credential-id: sonar-token-smo-ves
292 variable: SONAR_TOKEN
295 - lf-infra-tox-install:
296 python-version: "{python-version}"
297 - shell: "{pre-build-script}"
299 parallel: "{parallel}"
302 properties-content: |
303 SONARCLOUD_PROJECT_ORGANIZATION={sonarcloud-project-organization}
304 SONARCLOUD_PROJECT_KEY={sonarcloud-project-key}
305 - shell: !include-raw-escape: ../shell/sonar-cli.sh
311 name: "{project-name}-cli-sonar"
313 <<: *lf_python_common
316 ######################
317 # Default parameters #
318 ######################
320 gerrit_sonar_triggers:
321 - comment-added-contains-event:
322 comment-contains-value: '^Patch Set\s+\d+:\s+run-sonar\s*$'
324 #####################
325 # Job Configuration #
326 #####################
329 - lf-infra-gerrit-scm:
330 jenkins-ssh-credential: "{jenkins-ssh-credential}"
332 refspec: $GERRIT_REFSPEC
333 branch: $GERRIT_BRANCH
334 submodule-recursive: "{submodule-recursive}"
335 submodule-timeout: "{submodule-timeout}"
336 submodule-disable: "{submodule-disable}"
337 choosing-strategy: default
340 - timed: "{obj:cron}"
342 server-name: "{gerrit-server-name}"
343 trigger-on: "{obj:gerrit_sonar_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}"
358 name: "{project-name}-cli-sonar"
360 <<: *lf_python_common
364 - lf-infra-properties:
365 build-days-to-keep: "{build-days-to-keep}"
367 url: "{github-url}/{github-org}/{project}"
370 - lf-infra-github-scm:
371 url: "{git-clone-url}{github-org}/{project}"
372 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
374 submodule-recursive: "{submodule-recursive}"
375 submodule-timeout: "{submodule-timeout}"
376 submodule-disable: "{submodule-disable}"
377 choosing-strategy: default
378 jenkins-ssh-credential: "{jenkins-ssh-credential}"
381 - github-pull-request:
382 trigger-phrase: "^run-sonar$"
383 only-trigger-phrase: false
384 status-context: "Python Sonar"
387 white-list-target-branches:
389 included-regions: "{obj:github_included_regions}"
391 #########################
392 # Python Sonar with Tox #
393 #########################
395 - lf_tox_sonar: &lf_tox_sonar
398 ######################
399 # Default parameters #
400 ######################
402 branch: master # Sonar should always be run on master branch
403 build-days-to-keep: 7
405 cron: "H H * * *" # run daily
407 git-url: "$GIT_URL/$PROJECT"
408 github-url: "https://github.com"
409 java-version: openjdk11
410 mvn-global-settings: global-settings
414 mvn-settings: "{mvn-settings}"
417 pre-build-script: "# pre-build script goes here"
418 python-version: python3
419 sonar-mvn-goal: "sonar:sonar"
421 sonarcloud-project-key: ""
422 sonarcloud-project-organization: ""
423 sonarcloud-api-token: ""
424 sonarcloud-qualitygate-wait: false
425 # SonarCloud scan using jdk8 will become deprecated by Oct, 2020
426 # Projects not compatible with jdk11 can set java-version to something else
427 sonarcloud-java-version: openjdk11
429 submodule-recursive: true
430 submodule-timeout: 10
431 submodule-disable: false
434 scan-dev-branch: false
436 gerrit_trigger_file_paths:
437 - compare-type: REG_EXP
440 # github_included_regions MUST match gerrit_trigger_file_paths
441 github_included_regions:
444 #####################
445 # Job Configuration #
446 #####################
448 disabled: "{disable-job}"
451 - lf-infra-parameters:
455 - lf-infra-maven-parameters:
456 mvn-opts: "{mvn-opts}"
457 mvn-params: "{mvn-params}"
458 mvn-version: "{mvn-version}"
459 - lf-infra-tox-parameters:
461 tox-envs: "{tox-envs}"
463 name: ARCHIVE_ARTIFACTS
464 default: "{archive-artifacts}"
465 description: Artifacts to archive to the logs server.
468 # Sets an env var for shell scripts to be able to call the dynamically
469 # installed maven without having to calculate the path themselves.
470 # yamllint disable-line rule:line-length
471 default: "/w/tools/hudson.tasks.Maven_MavenInstallation/{mvn-version}/bin/mvn"
472 description: "Maven selector to be used by shell scripts"
474 name: SONAR_MAVEN_GOAL
475 default: "{sonar-mvn-goal}"
477 Maven goals to pass to the Sonar call. Typically sonar:sonar
478 however to use a specific version of the sonar-maven-plugin we
479 can call "org.codehaus.mojo:sonar-maven-plugin:3.3.0.603:sonar".
483 - lf-infra-tox-install:
484 python-version: "{python-version}"
485 - shell: "{pre-build-script}"
487 parallel: "{parallel}"
488 - lf-provide-maven-settings:
489 global-settings-file: "{mvn-global-settings}"
490 settings-file: "{mvn-settings}"
493 condition-kind: boolean-expression
494 condition-expression: "{sonarcloud}"
496 - shell: echo 'Using SonarCloud'
497 - lf-infra-maven-sonarcloud:
498 java-version: "{java-version}"
499 mvn-goals: "{mvn-goals}"
500 mvn-settings: "{mvn-settings}"
501 mvn-version: "{mvn-version}"
502 sonarcloud-project-key: "{sonarcloud-project-key}"
503 # yamllint disable-line rule:line-length
504 sonarcloud-project-organization: "{sonarcloud-project-organization}"
505 sonarcloud-api-token: "{sonarcloud-api-token}"
506 sonarcloud-java-version: "{sonarcloud-java-version}"
507 sonarcloud-qualitygate-wait: "{sonarcloud-qualitygate-wait}"
508 scan-dev-branch: "{scan-dev-branch}"
513 condition-kind: boolean-expression
514 condition-expression: "{sonarcloud}"
516 - shell: echo 'Using SonarQube'
517 - lf-infra-maven-sonar:
518 java-version: "{java-version}"
519 mvn-goals: "{mvn-goals}"
520 mvn-settings: "{mvn-settings}"
521 mvn-version: "{mvn-version}"
527 name: "{project-name}-tox-sonar"
529 <<: *lf_python_common
532 ######################
533 # Default parameters #
534 ######################
536 gerrit_sonar_triggers:
537 - comment-added-contains-event:
538 comment-contains-value: '^Patch Set\s+\d+:\s+run-sonar\s*$'
540 #####################
541 # Job Configuration #
542 #####################
545 - lf-infra-gerrit-scm:
546 jenkins-ssh-credential: "{jenkins-ssh-credential}"
548 refspec: $GERRIT_REFSPEC
549 branch: $GERRIT_BRANCH
550 submodule-recursive: "{submodule-recursive}"
551 submodule-timeout: "{submodule-timeout}"
552 submodule-disable: "{submodule-disable}"
553 choosing-strategy: default
556 - timed: "{obj:cron}"
558 server-name: "{gerrit-server-name}"
559 trigger-on: "{obj:gerrit_sonar_triggers}"
561 - project-compare-type: "ANT"
562 project-pattern: "{project}"
564 - branch-compare-type: "ANT"
565 branch-pattern: "**/{branch}"
566 file-paths: "{obj:gerrit_trigger_file_paths}"
574 name: "{project-name}-tox-sonar"
576 <<: *lf_python_common
580 - lf-infra-properties:
581 build-days-to-keep: "{build-days-to-keep}"
583 url: "{github-url}/{github-org}/{project}"
586 - lf-infra-github-scm:
587 url: "{git-clone-url}{github-org}/{project}"
588 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
590 submodule-recursive: "{submodule-recursive}"
591 submodule-timeout: "{submodule-timeout}"
592 submodule-disable: "{submodule-disable}"
593 choosing-strategy: default
594 jenkins-ssh-credential: "{jenkins-ssh-credential}"
597 - github-pull-request:
598 trigger-phrase: "^run-sonar$"
599 only-trigger-phrase: false
600 status-context: "Python Sonar"
603 white-list-target-branches:
605 included-regions: "{obj:github_included_regions}"
611 - lf_tox_sonarqube: &lf_tox_sonarqube
612 name: lf-tox-sonarqube
614 ######################
615 # Default parameters #
616 ######################
620 branch: master # Sonar should always be run on master branch
621 build-days-to-keep: 7
625 git-url: "$GIT_URL/$PROJECT"
626 github-url: "https://github.com"
628 pre-build-script: "# pre-build script goes here"
629 python-version: python3
631 submodule-recursive: true
632 submodule-timeout: 10
633 submodule-disable: false
637 sonar-additional-args: ""
639 sonar-project-file: "sonar-project.properties"
643 #####################
644 # Job Configuration #
645 #####################
647 project-type: freestyle
649 disabled: "{disable-job}"
652 - lf-infra-properties:
653 build-days-to-keep: "{build-days-to-keep}"
657 build-timeout: "{build-timeout}"
658 jenkins-ssh-credential: "{jenkins-ssh-credential}"
661 - lf-infra-parameters:
665 - lf-infra-tox-parameters:
667 tox-envs: "{tox-envs}"
669 name: ARCHIVE_ARTIFACTS
670 default: "{archive-artifacts}"
671 description: Artifacts to archive to the logs server.
675 - lf-infra-tox-install:
676 python-version: "{python-version}"
677 - shell: "{pre-build-script}"
679 parallel: "{parallel}"
681 sonar-task: "{sonar-task}"
682 sonar-project-file: "{sonar-project-file}"
683 sonar-properties: "{sonar-properties}"
684 sonar-java-opts: "{sonar-java-opts}"
685 sonar-additional-args: "{sonar-additional-args}"
691 name: "{project-name}-tox-sonarqube"
692 id: gerrit-tox-sonarqube
694 <<: *lf_tox_sonarqube
696 ######################
697 # Default parameters #
698 ######################
700 gerrit_sonar_triggers:
701 - comment-added-contains-event:
702 comment-contains-value: '^Patch Set\s+\d+:\s+run-sonar\s*$'
705 - lf-infra-gerrit-scm:
706 branch: "$GERRIT_BRANCH"
707 jenkins-ssh-credential: "{jenkins-ssh-credential}"
709 refspec: "$GERRIT_REFSPEC"
710 submodule-recursive: "{submodule-recursive}"
711 submodule-timeout: "{submodule-timeout}"
712 submodule-disable: "{submodule-disable}"
713 choosing-strategy: default
716 - timed: "{obj:cron}"
718 server-name: "{gerrit-server-name}"
719 trigger-on: "{obj:gerrit_sonar_triggers}"
721 - project-compare-type: "ANT"
722 project-pattern: "{project}"
724 - branch-compare-type: "ANT"
725 branch-pattern: "**/{branch}"
728 name: "{project-name}-tox-sonarqube"
729 id: github-tox-sonarqube
731 <<: *lf_tox_sonarqube
734 - lf-infra-github-scm:
736 jenkins-ssh-credential: "{jenkins-ssh-credential}"
737 url: "{git-clone-url}{github-org}/{project}"
738 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
739 submodule-recursive: "{submodule-recursive}"
740 submodule-timeout: "{submodule-timeout}"
741 submodule-disable: "{submodule-disable}"
742 choosing-strategy: default
745 - github-pull-request:
746 trigger-phrase: "^run-sonar$"
747 only-trigger-phrase: false
748 status-context: "Tox Sonarqube"
751 white-list-target-branches:
758 - lf_tox_common: &lf_tox_common
761 ######################
762 # Default parameters #
763 ######################
766 build-days-to-keep: 7
769 git-url: "$GIT_URL/$GERRIT_PROJECT"
770 github-url: "https://github.com"
772 pre-build-script: "# pre-build script goes here"
773 python-version: python3
775 submodule-recursive: true
776 submodule-timeout: 10
777 submodule-disable: false
781 gerrit_trigger_file_paths:
782 - compare-type: REG_EXP
785 # github_included_regions MUST match gerrit_trigger_file_paths
786 github_included_regions:
789 #####################
790 # Job Configuration #
791 #####################
793 project-type: freestyle
796 disabled: "{disable-job}"
799 - lf-infra-properties:
800 build-days-to-keep: "{build-days-to-keep}"
803 - lf-infra-parameters:
807 - lf-infra-tox-parameters:
809 tox-envs: "{tox-envs}"
813 build-timeout: "{build-timeout}"
814 jenkins-ssh-credential: "{jenkins-ssh-credential}"
818 - lf-infra-tox-install:
819 python-version: "{python-version}"
820 - shell: "{pre-build-script}"
822 parallel: "{parallel}"
828 # Python projects typically use tox to run testing.
829 name: "{project-name}-tox-verify-{stream}"
830 id: gerrit-tox-verify
833 ######################
834 # Default parameters #
835 ######################
837 gerrit-skip-vote: false
838 gerrit_verify_triggers:
839 - patchset-created-event:
841 exclude-trivial-rebase: false
842 exclude-no-code-change: false
843 - draft-published-event
844 - comment-added-contains-event:
845 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
847 #####################
848 # Job Configuration #
849 #####################
852 - lf-infra-gerrit-scm:
853 jenkins-ssh-credential: "{jenkins-ssh-credential}"
855 refspec: "$GERRIT_REFSPEC"
856 branch: "$GERRIT_BRANCH"
857 submodule-recursive: "{submodule-recursive}"
858 submodule-timeout: "{submodule-timeout}"
859 submodule-disable: "{submodule-disable}"
860 choosing-strategy: gerrit
864 server-name: "{gerrit-server-name}"
865 trigger-on: "{obj:gerrit_verify_triggers}"
867 - project-compare-type: ANT
868 project-pattern: "{project}"
870 - branch-compare-type: ANT
871 branch-pattern: "**/{branch}"
872 file-paths: "{obj:gerrit_trigger_file_paths}"
874 successful: "{gerrit-skip-vote}"
875 failed: "{gerrit-skip-vote}"
876 unstable: "{gerrit-skip-vote}"
877 notbuilt: "{gerrit-skip-vote}"
880 # Python projects typically use tox to run testing.
881 name: "{project-name}-tox-verify-{stream}"
882 id: github-tox-verify
886 - lf-infra-properties:
887 build-days-to-keep: "{build-days-to-keep}"
889 url: "{github-url}/{github-org}/{project}"
892 - lf-infra-github-scm:
893 url: "{git-clone-url}{github-org}/{project}"
894 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
896 submodule-recursive: "{submodule-recursive}"
897 submodule-timeout: "{submodule-timeout}"
898 submodule-disable: "{submodule-disable}"
899 choosing-strategy: default
900 jenkins-ssh-credential: "{jenkins-ssh-credential}"
903 - github-pull-request:
904 trigger-phrase: "^(recheck|reverify)$"
905 only-trigger-phrase: false
906 status-context: "Tox Verify"
909 white-list-target-branches:
911 included-regions: "{obj:github_included_regions}"
914 # Run tox after merge of gerrit change set
915 name: "{project-name}-tox-merge-{stream}"
919 ######################
920 # Default parameters #
921 ######################
923 gerrit_merge_triggers:
924 - change-merged-event
925 - comment-added-contains-event:
926 comment-contains-value: '^Patch Set\s+\d+:\s+remerge\s*$'
928 #####################
929 # Job Configuration #
930 #####################
933 - lf-infra-gerrit-scm:
934 jenkins-ssh-credential: "{jenkins-ssh-credential}"
936 refspec: "$GERRIT_REFSPEC"
937 branch: "$GERRIT_BRANCH"
938 submodule-recursive: "{submodule-recursive}"
939 submodule-timeout: "{submodule-timeout}"
940 submodule-disable: "{submodule-disable}"
941 # merge jobs always build from tip
942 choosing-strategy: default
946 server-name: "{gerrit-server-name}"
947 trigger-on: "{obj:gerrit_merge_triggers}"
949 - project-compare-type: ANT
950 project-pattern: "{project}"
952 - branch-compare-type: ANT
953 branch-pattern: "**/{branch}"
954 file-paths: "{obj:gerrit_trigger_file_paths}"
957 # Run tox after merge of github pull request
958 name: "{project-name}-tox-merge-{stream}"
963 - lf-infra-properties:
964 build-days-to-keep: "{build-days-to-keep}"
966 url: "{github-url}/{github-org}/{project}"
969 - lf-infra-github-scm:
970 url: "{git-clone-url}{github-org}/{project}"
972 branch: "refs/heads/{branch}"
973 submodule-recursive: "{submodule-recursive}"
974 submodule-timeout: "{submodule-timeout}"
975 submodule-disable: "{submodule-disable}"
976 choosing-strategy: default
977 jenkins-ssh-credential: "{jenkins-ssh-credential}"
980 - github-pull-request:
981 trigger-phrase: "^remerge$"
982 only-trigger-phrase: true
983 status-context: "Tox Merge"
988 white-list: "{obj:github_pr_allowlist}"
989 admin-list: "{obj:github_pr_admin_list}"
990 white-list-target-branches:
992 included-regions: "{obj:github_included_regions}"
998 - lf_pypi_common: &lf_pypi_common
1001 ######################
1002 # Default parameters #
1003 ######################
1005 archive-artifacts: >
1008 build-days-to-keep: 7
1012 git-url: "$GIT_URL/$GERRIT_PROJECT"
1013 github-url: "https://github.com"
1015 pre-build-script: "# pre-build script goes here"
1016 python-version: python3
1018 submodule-disable: false
1019 submodule-recursive: true
1020 submodule-timeout: 10
1024 gerrit_trigger_file_paths:
1025 - compare-type: REG_EXP
1028 # github_included_regions MUST match gerrit_trigger_file_paths
1029 github_included_regions:
1032 #####################
1033 # Job Configuration #
1034 #####################
1036 project-type: freestyle
1037 node: "{build-node}"
1038 disabled: "{disable-job}"
1041 - lf-infra-properties:
1042 build-days-to-keep: "{build-days-to-keep}"
1045 - lf-infra-parameters:
1046 project: "{project}"
1049 - lf-infra-tox-parameters:
1050 tox-dir: "{tox-dir}"
1051 tox-envs: "{tox-envs}"
1053 name: BUILD_BDIST_WHEEL
1054 default: "{dist-binary}"
1055 description: "Set to True (checked) to build a binary distribution"
1059 description: "Set to True (checked) to skip uploading artifacts"
1062 - lf-infra-wrappers:
1063 build-timeout: "{build-timeout}"
1064 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1069 - lf_pypi_verify_builders: &lf_pypi_verify_builders
1070 name: lf-pypi-verify-builders
1073 - lf-infra-pre-build
1074 - lf-infra-tox-install:
1075 python-version: "{python-version}"
1076 - shell: "{pre-build-script}"
1078 parallel: "{parallel}"
1079 - shell: !include-raw-escape: ../shell/pypi-dist-build.sh
1081 - lf_pypi_publish_builders: &lf_pypi_publish_builders
1082 name: lf-pypi-publish-builders
1085 - lf-infra-pre-build
1086 - lf-infra-tox-install:
1087 python-version: "{python-version}"
1088 - shell: "{pre-build-script}"
1090 parallel: "{parallel}"
1091 - shell: !include-raw-escape: ../shell/pypi-dist-build.sh
1092 - config-file-provider:
1095 target: "$HOME/.pypirc"
1097 properties-content: "REPOSITORY={pypi-repo}"
1098 - shell: !include-raw-escape: ../shell/pypi-upload.sh
1101 name: "{project-name}-pypi-verify-{stream}"
1102 id: gerrit-pypi-verify
1104 <<: *lf_pypi_verify_builders
1107 - lf-infra-gerrit-scm:
1108 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1109 git-url: "{git-url}"
1110 refspec: "$GERRIT_REFSPEC"
1111 branch: "$GERRIT_BRANCH"
1112 submodule-recursive: "{submodule-recursive}"
1113 submodule-timeout: "{submodule-timeout}"
1114 submodule-disable: "{submodule-disable}"
1115 choosing-strategy: gerrit
1119 server-name: "{gerrit-server-name}"
1121 - patchset-created-event:
1122 exclude-drafts: true
1123 exclude-trivial-rebase: false
1124 exclude-no-code-change: false
1125 - draft-published-event
1126 - comment-added-contains-event:
1127 # yamllint disable-line rule:line-length
1128 comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$'
1130 - project-compare-type: ANT
1131 project-pattern: "{project}"
1133 - branch-compare-type: ANT
1134 branch-pattern: "**/{branch}"
1135 file-paths: "{obj:gerrit_trigger_file_paths}"
1138 name: "{project-name}-pypi-verify-{stream}"
1139 id: github-pypi-verify
1141 <<: *lf_pypi_verify_builders
1145 url: "{github-url}/{github-org}/{project}"
1148 - lf-infra-github-scm:
1149 url: "{git-clone-url}{github-org}/{project}"
1150 refspec: "+refs/pull/*:refs/remotes/origin/pr/*"
1152 submodule-recursive: "{submodule-recursive}"
1153 submodule-timeout: "{submodule-timeout}"
1154 submodule-disable: "{submodule-disable}"
1155 choosing-strategy: default
1156 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1159 - github-pull-request:
1160 trigger-phrase: "^(recheck|reverify)$"
1161 only-trigger-phrase: false
1162 status-context: "PyPI Verify"
1165 white-list-target-branches:
1167 included-regions: "{obj:github_included_regions}"
1170 name: "{project-name}-pypi-merge-{stream}"
1171 id: gerrit-pypi-merge
1173 <<: *lf_pypi_publish_builders
1175 cron: "" # avoid for pypi which rejects duplicates
1176 pypi-repo: pypi-test
1179 - lf-infra-gerrit-scm:
1180 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1181 git-url: "{git-url}"
1182 refspec: "$GERRIT_REFSPEC"
1183 branch: "$GERRIT_BRANCH"
1184 submodule-recursive: "{submodule-recursive}"
1185 submodule-timeout: "{submodule-timeout}"
1186 submodule-disable: "{submodule-disable}"
1187 # merge jobs always build from tip
1188 choosing-strategy: default
1191 - timed: "{obj:cron}"
1193 server-name: "{gerrit-server-name}"
1195 - change-merged-event
1196 - comment-added-contains-event:
1197 comment-contains-value: '^Patch Set\s+\d+:\s+remerge\s*$'
1199 - project-compare-type: ANT
1200 project-pattern: "{project}"
1202 - branch-compare-type: ANT
1203 branch-pattern: "**/{branch}"
1204 file-paths: "{obj:gerrit_trigger_file_paths}"
1207 name: "{project-name}-pypi-merge-{stream}"
1208 id: github-pypi-merge
1210 <<: *lf_pypi_publish_builders
1213 pypi-repo: pypi-test
1217 url: "{github-url}/{github-org}/{project}"
1220 - lf-infra-github-scm:
1221 url: "{git-clone-url}{github-org}/{project}"
1223 branch: "refs/heads/{branch}"
1224 submodule-recursive: "{submodule-recursive}"
1225 submodule-timeout: "{submodule-timeout}"
1226 submodule-disable: "{submodule-disable}"
1227 choosing-strategy: default
1228 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1231 - timed: "{obj:cron}"
1232 - github-pull-request:
1233 trigger-phrase: "^remerge$"
1234 only-trigger-phrase: false
1235 status-context: "Merge"
1240 white-list: "{obj:github_pr_allowlist}"
1241 admin-list: "{obj:github_pr_admin_list}"
1242 white-list-target-branches:
1244 included-regions: "{obj:github_included_regions}"
1247 name: "{project-name}-pypi-stage-{stream}"
1248 id: gerrit-pypi-stage
1250 <<: *lf_pypi_publish_builders
1253 pypi-repo: pypi-test
1255 gerrit_stage_triggers:
1256 - comment-added-contains-event:
1257 comment-contains-value: '^Patch Set\s+\d+:\s+stage-release\s*$'
1260 - lf-infra-gerrit-scm:
1261 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1262 git-url: "{git-url}"
1263 refspec: "$GERRIT_REFSPEC"
1264 branch: "$GERRIT_BRANCH"
1265 submodule-recursive: "{submodule-recursive}"
1266 submodule-timeout: "{submodule-timeout}"
1267 submodule-disable: "{submodule-disable}"
1268 # stage jobs always build from tip
1269 choosing-strategy: default
1272 - timed: "{obj:cron}"
1274 server-name: "{gerrit-server-name}"
1275 trigger-on: "{obj:gerrit_stage_triggers}"
1277 - project-compare-type: ANT
1278 project-pattern: "{project}"
1280 - branch-compare-type: ANT
1281 branch-pattern: "**/{branch}"
1282 file-paths: "{obj:gerrit_trigger_file_paths}"
1285 name: "{project-name}-pypi-stage-{stream}"
1286 id: github-pypi-stage
1288 <<: *lf_pypi_publish_builders
1291 pypi-repo: pypi-test
1295 url: "{github-url}/{github-org}/{project}"
1298 - lf-infra-github-scm:
1299 url: "{git-clone-url}{github-org}/{project}"
1301 branch: "refs/heads/{branch}"
1302 submodule-recursive: "{submodule-recursive}"
1303 submodule-timeout: "{submodule-timeout}"
1304 submodule-disable: "{submodule-disable}"
1305 choosing-strategy: default
1306 jenkins-ssh-credential: "{jenkins-ssh-credential}"
1309 - timed: "{obj:cron}"
1310 - github-pull-request:
1311 trigger-phrase: "^stage-release$"
1312 only-trigger-phrase: true
1313 status-context: "Release"
1316 white-list-target-branches:
1318 included-regions: "{obj:github_included_regions}"