8 name: lf-infra-wss-unified-agent-scan
10 - config-file-provider:
12 - file-id: wss-unified-agent.config
13 target: $WORKSPACE/wss-unified-agent.config
14 - shell: !include-raw:
15 - ../shell/whitesource-unified-agent-cli.sh
21 - lf_whitesource_common: &lf_whitesource_common
22 name: lf-whitesource-common
24 ######################
25 # Default parameters #
26 ######################
35 project-type: freestyle
39 - lf-infra-properties:
40 build-days-to-keep: '{build-days-to-keep}'
43 - lf-infra-parameters:
50 build-timeout: '{build-timeout}'
51 jenkins-ssh-credential: '{jenkins-ssh-credential}'
52 - credentials-binding:
54 credential-id: wss-apiKey
60 ##################################
61 # WHITESOURCE UNIFIED AGENT SCAN #
62 ##################################
64 - lf_wss_unified_agent_scan: &lf_wss_unified_agent_scan
65 name: lf-wss-unified-agent-scan
67 ######################
68 # Default parameters #
69 ######################
72 build-days-to-keep: 30
76 git-url: '$GIT_URL/$PROJECT'
77 github-url: 'https://github.com'
78 java-version: openjdk8
80 submodule-recursive: true
82 wss-unified-agent-opts: ''
83 wss-unified-agent-version: 19.2.2.2
85 gerrit_trigger_file_paths:
89 # github_included_regions MUST match gerrit_trigger_file_paths
90 github_included_regions:
97 disabled: '{disable-job}'
100 - lf-infra-parameters:
105 name: WSS_PROJECT_NAME
106 default: '{project-name}'
107 description: Project to asociate the WhiteSource report in the dashboard.
109 name: WSS_PRODUCT_NAME
110 default: '{wss-product-name}'
111 description: Product to asociate the WhiteSource report in the dashboard.
113 name: WSS_UNIFIED_AGENT_OPTIONS
114 default: '{wss-unified-agent-opts}'
115 description: Options to pass to the WhiteSource Unified Agent CLI.
117 name: WSS_UNIFIED_AGENT_VERSION
118 default: '{wss-unified-agent-version}'
119 description: WhiteSource Unified Agent version package to download and use.
123 - lf-update-java-alternatives:
124 java-version: '{java-version}'
125 - lf-infra-wss-unified-agent-scan
128 name: '{project-name}-whitesource-scan-{stream}'
129 id: gerrit-whitesource-scan
130 <<: *lf_whitesource_common
131 # yamllint disable-line rule:key-duplicates
132 <<: *lf_wss_unified_agent_scan
134 ######################
135 # Default parameters #
136 ######################
139 - comment-added-contains-event:
140 comment-contains-value: run-whitesource$
142 #####################
143 # Job Configuration #
144 #####################
147 - lf-infra-gerrit-scm:
148 jenkins-ssh-credential: '{jenkins-ssh-credential}'
150 refspec: '$GERRIT_REFSPEC'
151 branch: '$GERRIT_BRANCH'
152 submodule-recursive: '{submodule-recursive}'
153 submodule-timeout: '{submodule-timeout}'
154 choosing-strategy: default
157 # Build weekly on Saturdays
158 - timed: '{obj:cron}'
160 server-name: '{gerrit-server-name}'
161 trigger-on: '{obj:gerrit_wss_triggers}'
163 - project-compare-type: ANT
164 project-pattern: '{project}'
166 - branch-compare-type: ANT
167 branch-pattern: '**/{branch}'
168 file-paths: '{obj:gerrit_trigger_file_paths}'
176 name: '{project-name}-whitesource-scan-{stream}'
177 id: github-whitesource-scan
178 <<: *lf_whitesource_common
179 # yamllint disable-line rule:key-duplicates
180 <<: *lf_wss_unified_agent_scan
183 - lf-infra-properties:
184 build-days-to-keep: '{build-days-to-keep}'
186 url: '{github-url}/{github-org}/{project}'
189 - lf-infra-github-scm:
190 url: '{git-clone-url}{github-org}/{project}'
192 branch: 'refs/heads/{branch}'
193 submodule-recursive: '{submodule-recursive}'
194 submodule-timeout: '{submodule-timeout}'
195 choosing-strategy: default
196 jenkins-ssh-credential: '{jenkins-ssh-credential}'
199 # Build weekly on Saturdays
200 - timed: '{obj:cron}'
201 - github-pull-request:
202 trigger-phrase: '^run-whitesource$'
203 only-trigger-phrase: false
204 status-context: 'WhiteSource'
207 white-list-target-branches:
209 included-regions: '{obj:github_included_regions}'