X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=jjb%2Flf-macros.yaml;h=08bb637c482146a23b20de7855a9411692bd2fbf;hb=46d42088f932b67b8a95b6426a84328932b8528e;hp=2e3a85711cd6e78218da9610ac0f316fda5150a0;hpb=67a293907edfcf3f4b7e2465f77b8cda40c0834f;p=releng%2Fglobal-jjb.git diff --git a/jjb/lf-macros.yaml b/jjb/lf-macros.yaml index 2e3a8571..08bb637c 100644 --- a/jjb/lf-macros.yaml +++ b/jjb/lf-macros.yaml @@ -56,6 +56,8 @@ - builder: name: lf-infra-ship-logs builders: + # Ensure no pre-existing .netrc files are overriding logs config + - lf-provide-maven-settings-cleanup - config-file-provider: files: - file-id: 'jenkins-log-archives-settings' @@ -81,6 +83,16 @@ - builder: name: lf-infra-packer-build builders: + - conditional-step: + condition-kind: boolean-expression + condition-expression: '{openstack}' + steps: + - config-file-provider: + files: + - file-id: clouds-yaml + target: '$HOME/.config/openstack/clouds.yaml' + - inject: + properties-content: OS_CLOUD={openstack-cloud} - config-file-provider: files: - file-id: '{packer-cloud-settings}' @@ -99,10 +111,20 @@ - builder: name: lf-infra-packer-validate builders: + - conditional-step: + condition-kind: boolean-expression + condition-expression: '{openstack}' + steps: + - config-file-provider: + files: + - file-id: clouds-yaml + target: '$HOME/.config/openstack/clouds.yaml' + - inject: + properties-content: OS_CLOUD={openstack-cloud} - config-file-provider: files: - file-id: '{packer-cloud-settings}' - variable: 'CLOUDENV' + variable: CLOUDENV - inject: properties-content: | PACKER_VERSION={packer-version} @@ -151,11 +173,23 @@ GROUP_ID={group-id} UPLOAD_FILES_PATH={upload-files-dir} - shell: !include-raw-escape: - - ../shell/lftools-install.sh - ../shell/common-variables.sh - ../shell/deploy-maven-file.sh - lf-provide-maven-settings-cleanup +- builder: + name: lf-maven-central + builders: + - conditional-step: + condition-kind: boolean-expression + condition-expression: '{mvn-central}' + steps: + - lf-infra-create-netrc: + server-id: 'ossrh' + - inject: + properties-content: 'OSSRH_PROFILE_ID={ossrh-profile-id}' + - shell: !include-raw-escape: ../shell/maven-central.sh + - builder: name: lf-maven-install builders: @@ -214,9 +248,8 @@ builders: - inject: properties-content: DOC_DIR={doc-dir} - - shell: !include-raw-escape: - - ../shell/tox-install.sh - - ../shell/rtd-verify.sh + - shell: !include-raw-escape: ../shell/tox-install.sh + - shell: !include-raw-escape: ../shell/rtd-verify.sh - builder: name: lf-sigul-sign-dir @@ -386,15 +419,6 @@ If using GitHub, in a manual build override with a branch path or sha1 hash to a specific commit. For example: 'origin/master' - # Tools - - string: - name: LFTOOLS_VERSION - default: '{lftools-version}' - description: | - Version of lftools to install. Can be a specific version like - '0.6.0' or a PEP-440 definition. - https://www.python.org/dev/peps/pep-0440/ - For example '<1.0.0' or '>=1.0.0,<2.0.0'. - parameter: name: lf-infra-node-parameters @@ -488,6 +512,34 @@ - '**/*.jenkins-trigger' fail-build: false +- publisher: + name: lf-infra-publish-windows + # lf-infra macro to finish up a build. + # + # Handles the following: + # - Shipping logs to Nexus logs site repository + # - Cleanup workspace + publishers: + # TODO: RELENG-1228 Develop log shipping script for Windows systems + # - postbuildscript: + # builders: + # - role: BOTH + # build-on: + # - ABORTED + # - FAILURE + # - NOT_BUILT + # - SUCCESS + # - UNSTABLE + # build-steps: + # - lf-infra-ship-logs-windows + # mark-unstable-if-failed: true + - workspace-cleanup: + exclude: + # Do not clean up *.jenkins-trigger files for jobs that use a + # properties file as input for triggering another build. + - '**/*.jenkins-trigger' + fail-build: false + ####### # SCM # ####### @@ -505,6 +557,7 @@ wipe-workspace: true submodule: recursive: '{submodule-recursive}' + timeout: '{submodule-timeout}' choosing-strategy: '{choosing-strategy}' - scm: @@ -520,6 +573,7 @@ wipe-workspace: true submodule: recursive: '{submodule-recursive}' + timeout: '{submodule-timeout}' choosing-strategy: '{choosing-strategy}' ############ @@ -527,7 +581,7 @@ ############ - wrapper: - name: lf-infra-wrappers + name: lf-infra-wrappers-common wrappers: - mask-passwords - timeout: @@ -536,14 +590,26 @@ timeout-var: 'BUILD_TIMEOUT' fail: true - timestamps - - ssh-agent-credentials: - users: - - '{jenkins-ssh-credential}' - openstack: single-use: true + +- wrapper: + name: lf-infra-wrappers + wrappers: + - lf-infra-wrappers-common: + build-timeout: '{build-timeout}' - config-file-provider: files: - file-id: npmrc target: '$HOME/.npmrc' - file-id: pipconf target: '$HOME/.config/pip/pip.conf' + - ssh-agent-credentials: + users: + - '{jenkins-ssh-credential}' + +- wrapper: + name: lf-infra-wrappers-windows + wrappers: + - lf-infra-wrappers-common: + build-timeout: '{build-timeout}'