Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 1 | # Copyright (c) 2019 AT&T Intellectual Property. |
| 2 | # |
| 3 | # Licensed under the Apache License, Version 2.0 (the 'License'); |
| 4 | # you may not use this file except in compliance with the License. |
| 5 | # You may obtain a copy of the License at |
| 6 | # |
| 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an 'AS IS' BASIS, |
| 11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | # See the License for the specific language governing permissions and |
| 13 | # limitations under the License. |
| 14 | --- |
Anil Belur | 4e0d56a | 2023-04-18 11:49:03 +1000 | [diff] [blame] | 15 | - _oran_shell_common: &oran_shell_common |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 16 | name: oran-shell-common |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 17 | |
| 18 | ###################### |
| 19 | # Default parameters # |
| 20 | ###################### |
| 21 | |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 22 | archive-artifacts: > |
| 23 | **/*.log |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 24 | branch: master |
Lott, Christopher (cl778h) | 2984c9e | 2020-01-15 10:37:25 -0500 | [diff] [blame] | 25 | build-days-to-keep: 30 |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 26 | build-timeout: 15 |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 27 | cron: "" |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 28 | concurrent: false |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 29 | disable-job: false |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 30 | gerrit-skip-vote: false |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 31 | git-url: "$GIT_URL/$GERRIT_PROJECT" |
Lott, Christopher (cl778h) | d59c1b8 | 2019-11-14 09:06:25 -0500 | [diff] [blame] | 32 | mvn-global-settings: global-settings |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 33 | stream: master |
| 34 | submodule-disable: false |
| 35 | submodule-recursive: true |
| 36 | submodule-timeout: 10 |
| 37 | |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 38 | gerrit_trigger_file_paths: |
| 39 | - compare-type: REG_EXP |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 40 | pattern: ".*" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 41 | |
| 42 | ##################### |
| 43 | # Job Configuration # |
| 44 | ##################### |
| 45 | |
| 46 | project-type: freestyle |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 47 | node: "{build-node}" |
| 48 | disabled: "{disable-job}" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 49 | |
| 50 | properties: |
| 51 | - lf-infra-properties: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 52 | build-days-to-keep: "{build-days-to-keep}" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 53 | |
| 54 | parameters: |
| 55 | - lf-infra-parameters: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 56 | project: "{project}" |
| 57 | branch: "{branch}" |
| 58 | stream: "{stream}" |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 59 | - string: |
| 60 | name: ARCHIVE_ARTIFACTS |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 61 | default: "{archive-artifacts}" |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 62 | description: Artifacts to archive to the logs server. |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 63 | |
| 64 | wrappers: |
| 65 | - lf-infra-wrappers: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 66 | build-timeout: "{build-timeout}" |
| 67 | jenkins-ssh-credential: "{jenkins-ssh-credential}" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 68 | |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 69 | builders: |
Lott, Christopher (cl778h) | d59c1b8 | 2019-11-14 09:06:25 -0500 | [diff] [blame] | 70 | - lf-infra-pre-build |
| 71 | - lf-provide-maven-settings: |
| 72 | global-settings-file: "{mvn-global-settings}" |
| 73 | settings-file: "{mvn-settings}" |
| 74 | - lf-infra-create-netrc: |
| 75 | server-id: "{mvn-site-id}" |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 76 | - shell: "{script}" |
Lott, Christopher (cl778h) | d59c1b8 | 2019-11-14 09:06:25 -0500 | [diff] [blame] | 77 | - lf-provide-maven-settings-cleanup |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 78 | |
| 79 | publishers: |
| 80 | - lf-infra-publish |
| 81 | |
| 82 | # Verify gerrit changeset by shell script. |
| 83 | # Runs on changeset branch to verify new commits; can be run on any branch. |
| 84 | # |
| 85 | # Required parameters: |
| 86 | # build-node: label (flavor) of jenkins build minion |
| 87 | # project: git repository |
| 88 | # project-name: Jenkins job name prefix |
| 89 | # script: shell script to execute |
| 90 | # Optional parameters: |
| 91 | # branch: git branch pattern, defaults to master |
| 92 | # stream: friendly stream name (often same as branch), defaults to master |
| 93 | - job-template: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 94 | name: "{project-name}-shell-verify-{stream}" |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 95 | id: oran-shell-verify |
| 96 | <<: *oran_shell_common |
| 97 | |
| 98 | gerrit_verify_triggers: |
| 99 | - patchset-created-event: |
| 100 | exclude-drafts: true |
| 101 | exclude-trivial-rebase: false |
| 102 | exclude-no-code-change: false |
| 103 | - draft-published-event |
| 104 | - comment-added-contains-event: |
| 105 | comment-contains-value: '^Patch Set\s+\d+:\s+(recheck|reverify)\s*$' |
| 106 | |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 107 | scm: |
| 108 | - lf-infra-gerrit-scm: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 109 | jenkins-ssh-credential: "{jenkins-ssh-credential}" |
| 110 | git-url: "{git-url}" |
| 111 | refspec: "$GERRIT_REFSPEC" |
| 112 | branch: "$GERRIT_BRANCH" |
| 113 | submodule-recursive: "{submodule-recursive}" |
| 114 | submodule-timeout: "{submodule-timeout}" |
| 115 | submodule-disable: "{submodule-disable}" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 116 | choosing-strategy: gerrit |
| 117 | |
| 118 | triggers: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 119 | - timed: "{obj:cron}" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 120 | - gerrit: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 121 | server-name: "{gerrit-server-name}" |
| 122 | trigger-on: "{obj:gerrit_verify_triggers}" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 123 | projects: |
| 124 | - project-compare-type: ANT |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 125 | project-pattern: "{project}" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 126 | branches: |
| 127 | - branch-compare-type: ANT |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 128 | branch-pattern: "**/{branch}" |
| 129 | file-paths: "{obj:gerrit_trigger_file_paths}" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 130 | skip-vote: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 131 | successful: "{gerrit-skip-vote}" |
| 132 | failed: "{gerrit-skip-vote}" |
| 133 | unstable: "{gerrit-skip-vote}" |
| 134 | notbuilt: "{gerrit-skip-vote}" |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 135 | |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 136 | # Build from gerrit by shell script. |
| 137 | # Triggered automatically by merge; can be run on any branch. |
| 138 | # |
| 139 | # Required parameters: |
| 140 | # build-node: label (flavor) of jenkins build minion |
| 141 | # project: git repository |
| 142 | # project-name: Jenkins job name prefix |
| 143 | # script: shell script to execute |
| 144 | # Optional parameters: |
| 145 | # branch: git branch pattern, defaults to master |
| 146 | # stream: friendly stream name (often same as branch), defaults to master |
| 147 | - job-template: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 148 | name: "{project-name}-shell-merge-{stream}" |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 149 | id: oran-shell-merge |
| 150 | <<: *oran_shell_common |
Lott, Christopher (cl778h) | 4e00eb9 | 2019-10-29 15:52:35 -0400 | [diff] [blame] | 151 | |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 152 | gerrit_merge_triggers: |
| 153 | - change-merged-event |
| 154 | - comment-added-contains-event: |
| 155 | comment-contains-value: '^Patch Set\s+\d+:\s+remerge\s*$' |
| 156 | |
| 157 | scm: |
| 158 | - lf-infra-gerrit-scm: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 159 | jenkins-ssh-credential: "{jenkins-ssh-credential}" |
| 160 | git-url: "{git-url}" |
| 161 | refspec: "$GERRIT_REFSPEC" |
| 162 | branch: "$GERRIT_BRANCH" |
| 163 | submodule-recursive: "{submodule-recursive}" |
| 164 | submodule-timeout: "{submodule-timeout}" |
| 165 | submodule-disable: "{submodule-disable}" |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 166 | choosing-strategy: default |
| 167 | |
| 168 | triggers: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 169 | - timed: "{obj:cron}" |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 170 | - gerrit: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 171 | server-name: "{gerrit-server-name}" |
| 172 | trigger-on: "{obj:gerrit_merge_triggers}" |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 173 | projects: |
| 174 | - project-compare-type: ANT |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 175 | project-pattern: "{project}" |
Lott, Christopher (cl778h) | f77c9f6 | 2019-11-08 13:39:36 -0500 | [diff] [blame] | 176 | branches: |
| 177 | - branch-compare-type: ANT |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 178 | branch-pattern: "**/{branch}" |
| 179 | file-paths: "{obj:gerrit_trigger_file_paths}" |
Bin Yang | 5d9c5ea | 2020-02-19 11:43:58 +0800 | [diff] [blame] | 180 | |
| 181 | # Build and publish artifact from gerrit by shell script. |
| 182 | # Triggered automatically by merging specific release file; |
| 183 | # can be run on any branch. |
| 184 | # |
| 185 | # Required parameters: |
| 186 | # build-node: label (flavor) of jenkins build minion |
| 187 | # project: git repository |
| 188 | # project-name: Jenkins job name prefix |
| 189 | # script: shell script to execute |
| 190 | # Optional parameters: |
| 191 | # branch: git branch pattern, defaults to master |
| 192 | # stream: friendly stream name (often same as branch), defaults to master |
| 193 | # gerrit_release_file_paths: Pathname pattern of the release file to trigger this job |
| 194 | - job-template: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 195 | name: "{project-name}-shell-release-{stream}" |
Bin Yang | 5d9c5ea | 2020-02-19 11:43:58 +0800 | [diff] [blame] | 196 | id: oran-shell-release |
| 197 | <<: *oran_shell_common |
| 198 | |
| 199 | gerrit_release_file_paths: |
| 200 | - compare-type: REG_EXP |
| 201 | pattern: 'releases\/oran-shell-release.*\.yaml' |
| 202 | |
| 203 | scm: |
| 204 | - lf-infra-gerrit-scm: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 205 | jenkins-ssh-credential: "{jenkins-ssh-credential}" |
| 206 | git-url: "{git-url}" |
| 207 | refspec: "$GERRIT_REFSPEC" |
| 208 | branch: "$GERRIT_BRANCH" |
| 209 | submodule-recursive: "{submodule-recursive}" |
| 210 | submodule-timeout: "{submodule-timeout}" |
| 211 | submodule-disable: "{submodule-disable}" |
Bin Yang | 5d9c5ea | 2020-02-19 11:43:58 +0800 | [diff] [blame] | 212 | choosing-strategy: default |
| 213 | |
| 214 | triggers: |
| 215 | - gerrit: |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 216 | server-name: "{gerrit-server-name}" |
Bin Yang | 5d9c5ea | 2020-02-19 11:43:58 +0800 | [diff] [blame] | 217 | trigger-on: |
| 218 | - change-merged-event |
| 219 | projects: |
| 220 | - project-compare-type: ANT |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 221 | project-pattern: "{project}" |
Bin Yang | 5d9c5ea | 2020-02-19 11:43:58 +0800 | [diff] [blame] | 222 | branches: |
| 223 | - branch-compare-type: ANT |
Anil Belur | 439502c | 2023-05-07 12:39:38 +1000 | [diff] [blame] | 224 | branch-pattern: "**/{branch}" |
| 225 | file-paths: "{obj:gerrit_release_file_paths}" |