X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=jjb%2Flf-python-jobs.yaml;h=e07810caf1846c1740bfd4faf2a30b32ef0a4d0e;hb=ef1c5879193bf4eac7899ca993ee1e40a29779d5;hp=904a3f1638d912af61121fc2727c15a468df1be5;hpb=572515e4e8f5e114a8b3c10728a37f5ef3a6ce58;p=releng%2Fglobal-jjb.git diff --git a/jjb/lf-python-jobs.yaml b/jjb/lf-python-jobs.yaml index 904a3f16..e07810ca 100644 --- a/jjb/lf-python-jobs.yaml +++ b/jjb/lf-python-jobs.yaml @@ -17,6 +17,17 @@ jobs: - github-tox-verify +########## +# Macros # +########## + +- builder: + name: lf-infra-tox-install + builders: + - inject: + properties-content: 'PYTHON_VERSION={python-version}' + - shell: !include-raw-escape: ../shell/tox-install.sh + ############## # Tox Verify # ############## @@ -24,40 +35,15 @@ - lf_tox_verify: &lf_tox_verify name: lf-tox-verify - # Tox runner to verify a project - # - # Runs tox to verify a project. - # - # Required Parameters: - # - # :build-node: The node to run build on. - # :jenkins-ssh-credential: Credential to use for SSH. (Generally should - # be configured in defaults.yaml) - # - # Optional Parameters: - # - # :branch: The branch to build against. (default: master) - # :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7) - # :build-timeout: Timeout in seconds before aborting build. (default: 10) - # :git-url: URL clone project from. (default: $GIT_URL/$PROJECT) - # :stream: Keyword that can be used to represent a release code-name. - # Often the same as the branch. (default: master) - # :submodule-recursive: Whether to checkout submodules recursively. - # (default: true) - # :tox-dir: Directory containing the project's tox.ini relative to - # the workspace. Empty works if tox.ini is at project root. - # (default: '') - # :tox-envs: Tox environments to run. If blank run everything described - # in tox.ini. (default: '') - ###################### # Default parameters # ###################### branch: master build-days-to-keep: 7 - build-timeout: 10 + build-timeout: 15 git-url: '$GIT_URL/$GERRIT_PROJECT' + python-version: python2 stream: master submodule-recursive: true tox-dir: '' @@ -96,9 +82,9 @@ # Without running the install first the run in the publisher will fail # due to missing lftools because it gets installed into a tox venv. - ../shell/lftools-install.sh - - shell: !include-raw-escape: - - ../shell/tox-install.sh - - ../shell/tox-run.sh + - lf-infra-tox-install: + python-version: '{python-version}' + - shell: !include-raw-escape: ../shell/tox-run.sh publishers: - lf-infra-publish @@ -160,7 +146,7 @@ - lf-infra-github-scm: url: '{git-clone-url}{github-org}/{project}' refspec: '+refs/pull/*:refs/remotes/origin/pr/*' - branch: '{branch}' + branch: '$sha1' submodule-recursive: '{submodule-recursive}' choosing-strategy: default jenkins-ssh-credential: '{jenkins-ssh-credential}'