---
+# ============LICENSE_START====================================================
+# Copyright (C) 2020 Nordix Foundation.
+# =============================================================================
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+# SPDX-License-Identifier: Apache-2.0
+# ============LICENSE_END======================================================
# this job gets triggered when a change is proposed to cicd/jjb
-# the change is verified using jenkins-jobs test command
+# the change is verified using jenkins-jobs tox test command
# result will be send to Gerrit in the form of Verified +1 or -1
-- project:
+- project:
name: infra-jjb-verify
-
project: infra/cicd
-
stream:
- master:
branch: '{stream}'
+ lint-type:
+ - jjbtest
+ - shellcheck
+ - yamllint
+
jobs:
- - infra-jjb-verify-{stream}
+ - infra-verify-cicd-jjb-{stream}
+ - infra-verify-cicd-{lint-type}-{stream}
- job-template:
- name: infra-jjb-verify-{stream}
-
- node: ubuntu1804
-
+ name: infra-verify-cicd-jjb-{stream}
+ project-type: multijob
+ node: infra-tools-docker-slave-ubuntu1804
disabled: false
-
concurrent: true
parameters:
- - infra-parameters
- project-parameters:
project: '{project}'
branch: '{branch}'
+ description: 'The project and branch which the change is proposed for'
+ - string:
+ name: VERBOSITY
+ default: 'false'
+ description: 'Verbosity setting for the lint script'
- nordix-gerrit-parameters
+ properties:
+ - logrotate
+
+ wrappers:
+ - build-timeout:
+ timeout: 60
+ - fix-workspace-permissions
+
scm:
- git-scm-gerrit:
ssh-credentials-id: nordixinfra-nordix-gerrit-ssh
branch: '{branch}'
refspec: $GERRIT_REFSPEC
+ wipe_workspace: true
+ clean_before: false
triggers:
- nordix-gerrit-trigger-patchset-created:
unstable: false
notbuilt: false
+ builders:
+ - multijob:
+ name: JJB Static Analysis
+ condition: ALWAYS
+ execution-type: PARALLEL
+ projects:
+ - name: 'infra-verify-cicd-jjbtest-{stream}'
+ current-parameters: true
+ kill-phase-on: NEVER
+ abort-all-job: false
+ - name: 'infra-verify-cicd-shellcheck-{stream}'
+ current-parameters: true
+ kill-phase-on: NEVER
+ abort-all-job: false
+ - name: 'infra-verify-cicd-yamllint-{stream}'
+ current-parameters: true
+ kill-phase-on: NEVER
+ abort-all-job: false
+
+- job-template:
+ name: 'infra-verify-cicd-{lint-type}-{stream}'
+ node: infra-tools-docker-slave-ubuntu1804
+ disabled: '{obj:disabled}'
+ concurrent: true
+
+ parameters:
+ - string:
+ name: LINT_TYPE
+ default: '{lint-type}'
+ description: 'Lint type to run'
+
+ properties:
+ - logrotate
+
wrappers:
- - nordixinfra-jjb-creds-wrapper
+ - build-timeout:
+ timeout: 150
+ - fix-workspace-permissions
+
+ scm:
+ - git-scm-gerrit:
+ ssh-credentials-id: nordixinfra-nordix-gerrit-ssh
+ branch: refs/heads/$GERRIT_BRANCH
+ refspec: $GERRIT_REFSPEC
+ wipe_workspace: true
+ clean_before: false
builders:
- shell:
- !include-raw-escape: ./jjb-verify.sh
+ !include-raw-escape: ./lint.sh
+
+# vim: set ts=2 sw=2 ft=yaml expandtab: