blob: 632bc8e2a019ada4bc1fd4788116636dc7f100c5 [file] [log] [blame]
Vanessa Rene Valderrama295975d2018-02-27 15:10:17 -08001---
2# Job definition Anchors
3- pypi_job_boiler_plate: &pypi_job_boiler_plate
4 name: pypi_job_boiler_plate
5
6 #####################
7 # Job Variables #
8 #####################
9
10 gerrit_merge_triggers:
11 - change-merged-event
12 - comment-added-contains-event:
13 comment-contains-value: pypi-remerge$
14
15 gerrit_release_trigger:
16 - comment-added-contains-event:
17 comment-contains-value: pypi-release$
18
19 gerrit_trigger_file_paths:
20 - compare-type: ANT
21 pattern: '**'
22
23 #####################
24 # Job Configuration #
25 #####################
26
27 project-type: freestyle
28 node: '{build-node}'
29
30 parameters:
31 - lf-infra-parameters:
32 project: '{project}'
33 branch: '{branch}'
34 stream: '{stream}'
35 lftools-version: '{lftools-version}'
36 - lf-infra-tox-parameters:
37 tox-dir: '{tox-dir}'
38 tox-envs: '{tox-envs}'
39
40
41 properties:
42 - lf-infra-properties:
43 build-days-to-keep: '{build-days-to-keep}'
44
45 scm:
46 - lf-infra-gerrit-scm:
47 jenkins-ssh-credential: '{jenkins-ssh-credential}'
48 git-url: '$GIT_URL/$PROJECT'
49 refspec: '$GERRIT_REFSPEC'
50 branch: '$GERRIT_BRANCH'
51 submodule-recursive: true
52 choosing-strategy: default
53
54 wrappers:
55 - lf-infra-wrappers:
56 build-timeout: '{build-timeout}'
57 jenkins-ssh-credential: '{jenkins-ssh-credential}'
58
59 publishers:
60 - lf-infra-publish
61
62- job-template:
63 name: '{project-name}-python-staging-{stream}'
64
65 # Job template for PyPI staging jobs
66 # Daily Builds
67
68 <<: *pypi_job_boiler_plate
69
70 triggers:
71 - gerrit:
72 server-name: '{gerrit-server-name}'
73 trigger-on: '{obj:gerrit_merge_triggers}'
74 projects:
75 - project-compare-type: ANT
76 project-pattern: '{project}'
77 branches:
78 - branch-compare-type: ANT
79 branch-pattern: '**/{branch}'
80 file-paths: '{obj:gerrit_trigger_file_paths}'
81
82 builders:
83 - lf-infra-tox-install:
84 python-version: '{python-version}'
85 - shell: !include-raw-escape: ../global-jjb/shell/tox-run.sh
86 - config-file-provider:
87 files:
88 - file-id: pypirc
89 target: '$HOME/.pypirc'
90 - shell:
Thanh Ha0f343ee2018-04-14 14:22:42 -040091 !include-raw-escape: ../../shell/pypi-dist-build.sh
Vanessa Rene Valderrama295975d2018-02-27 15:10:17 -080092
93 - publish-pypi:
94 pypi-server: staging
95
96- job-template:
97 name: '{project-name}-python-release-{stream}'
98
99 # Job template for PyPI release jobs
100
101 <<: *pypi_job_boiler_plate
102
103 triggers:
104 - gerrit:
105 server-name: '{gerrit-server-name}'
106 trigger-on: '{obj:gerrit_release_trigger}'
107 projects:
108 - project-compare-type: ANT
109 project-pattern: '{project}'
110 branches:
111 - branch-compare-type: ANT
112 branch-pattern: '**/{branch}'
113 file-paths: '{obj:gerrit_trigger_file_paths}'
114
115 builders:
116 - lf-infra-tox-install:
117 python-version: '{python-version}'
118 - shell: !include-raw-escape: ../global-jjb/shell/tox-run.sh
119 - config-file-provider:
120 files:
121 - file-id: pypirc
122 target: '$HOME/.pypirc'
123 - shell:
Thanh Ha0f343ee2018-04-14 14:22:42 -0400124 !include-raw-escape: ../../shell/pypi-dist-build.sh
Vanessa Rene Valderrama295975d2018-02-27 15:10:17 -0800125
126 - publish-pypi:
127 pypi-server: release
128
129- job-template:
130 name: '{project-name}-{subproject}-python-staging-{stream}'
131
132 # Job template for PyPI staging jobs
133 # Daily Builds
134
135 <<: *pypi_job_boiler_plate
136
137 triggers:
138 - gerrit:
139 server-name: '{gerrit-server-name}'
140 trigger-on: '{obj:gerrit_merge_triggers}'
141 projects:
142 - project-compare-type: ANT
143 project-pattern: '{project}'
144 branches:
145 - branch-compare-type: ANT
146 branch-pattern: '**/{branch}'
147 file-paths: '{obj:gerrit_trigger_file_paths}'
148
149 builders:
150 - lf-infra-tox-install:
151 python-version: '{python-version}'
152 - shell: !include-raw-escape: ../global-jjb/shell/tox-run.sh
153 - config-file-provider:
154 files:
155 - file-id: pypirc
156 target: '$HOME/.pypirc'
157 - shell:
Thanh Ha0f343ee2018-04-14 14:22:42 -0400158 !include-raw-escape: ../../shell/pypi-dist-build.sh
Vanessa Rene Valderrama295975d2018-02-27 15:10:17 -0800159
160 - publish-pypi:
161 pypi-server: staging
162
163- job-template:
164 name: '{project-name}-{subproject}-python-release-{stream}'
165
166 # Job template for PyPI release jobs
167
168 <<: *pypi_job_boiler_plate
169
170 triggers:
171 - gerrit:
172 server-name: '{gerrit-server-name}'
173 trigger-on: '{obj:gerrit_release_trigger}'
174 projects:
175 - project-compare-type: ANT
176 project-pattern: '{project}'
177 branches:
178 - branch-compare-type: ANT
179 branch-pattern: '**/{branch}'
180 file-paths: '{obj:gerrit_trigger_file_paths}'
181
182 builders:
183 - lf-infra-tox-install:
184 python-version: '{python-version}'
185 - shell: !include-raw-escape: ../global-jjb/shell/tox-run.sh
186 - config-file-provider:
187 files:
188 - file-id: pypirc
189 target: '$HOME/.pypirc'
190 - shell:
Thanh Ha0f343ee2018-04-14 14:22:42 -0400191 !include-raw-escape: ../../shell/pypi-dist-build.sh
Vanessa Rene Valderrama295975d2018-02-27 15:10:17 -0800192
193 - publish-pypi:
194 pypi-server: release