Merge changes I7d7323b8,Ib796cfee
authorAnil Shashikumar Belur <abelur@linuxfoundation.org>
Tue, 15 Aug 2017 00:38:04 +0000 (00:38 +0000)
committerGerrit Code Review <gerrit@linuxfoundation.org>
Tue, 15 Aug 2017 00:38:04 +0000 (00:38 +0000)
* changes:
  Add default refspec reference
  Refactor packer ci templates

22 files changed:
1  2 
jjb-test/expected-xml/gerrit-ciman-jjb-merge
jjb-test/expected-xml/gerrit-ciman-jjb-verify
jjb-test/expected-xml/gerrit-ciman-packer-merge-centos-java-builder
jjb-test/expected-xml/gerrit-ciman-packer-merge-centos-mininet
jjb-test/expected-xml/gerrit-ciman-packer-merge-ubuntu1604-java-builder
jjb-test/expected-xml/gerrit-ciman-packer-merge-ubuntu1604-mininet
jjb-test/expected-xml/gerrit-ciman-packer-verify
jjb-test/expected-xml/gerrit-maven-maven-clm-master
jjb-test/expected-xml/gerrit-maven-maven-release-master
jjb-test/expected-xml/gerrit-python-tox-verify-master
jjb-test/expected-xml/github-ciman-jjb-merge
jjb-test/expected-xml/github-ciman-jjb-verify
jjb-test/expected-xml/github-ciman-packer-merge-centos-java-builder
jjb-test/expected-xml/github-ciman-packer-merge-centos-mininet
jjb-test/expected-xml/github-ciman-packer-merge-ubuntu1604-java-builder
jjb-test/expected-xml/github-ciman-packer-merge-ubuntu1604-mininet
jjb-test/expected-xml/github-ciman-packer-verify
jjb-test/expected-xml/github-maven-maven-clm-master
jjb-test/expected-xml/github-maven-maven-release-master
jjb-test/expected-xml/github-python-tox-verify-master
jjb/lf-ci-jobs.yaml
jjb/lf-macros.yaml

@@@ -62,17 -62,8 +62,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>JJB_VERSION</name>
            <description>Jenkins Job Builder version to download and install.</description>
@@@ -343,39 -334,6 +343,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -384,32 -342,7 +384,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -62,17 -62,8 +62,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>JJB_VERSION</name>
            <description>Jenkins Job Builder version to download and install.</description>
@@@ -436,39 -427,6 +436,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -477,32 -435,7 +477,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -5,7 -5,7 +5,7 @@@
    <keepDependencies>false</keepDependencies>
    <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
    <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
-   <concurrentBuild>true</concurrentBuild>
+   <concurrentBuild>false</concurrentBuild>
    <assignedNode>build-vm</assignedNode>
    <canRoam>false</canRoam>
    <properties>
@@@ -62,17 -62,8 +62,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -524,39 -515,6 +524,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -565,32 -523,7 +565,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -5,7 -5,7 +5,7 @@@
    <keepDependencies>false</keepDependencies>
    <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
    <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
-   <concurrentBuild>true</concurrentBuild>
+   <concurrentBuild>false</concurrentBuild>
    <assignedNode>build-vm</assignedNode>
    <canRoam>false</canRoam>
    <properties>
@@@ -62,17 -62,8 +62,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -524,39 -515,6 +524,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -565,32 -523,7 +565,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -5,7 -5,7 +5,7 @@@
    <keepDependencies>false</keepDependencies>
    <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
    <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
-   <concurrentBuild>true</concurrentBuild>
+   <concurrentBuild>false</concurrentBuild>
    <assignedNode>build-vm</assignedNode>
    <canRoam>false</canRoam>
    <properties>
@@@ -62,17 -62,8 +62,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -524,39 -515,6 +524,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -565,32 -523,7 +565,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -5,7 -5,7 +5,7 @@@
    <keepDependencies>false</keepDependencies>
    <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
    <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
-   <concurrentBuild>true</concurrentBuild>
+   <concurrentBuild>false</concurrentBuild>
    <assignedNode>build-vm</assignedNode>
    <canRoam>false</canRoam>
    <properties>
@@@ -62,17 -62,8 +62,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -524,39 -515,6 +524,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -565,32 -523,7 +565,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -62,17 -62,8 +62,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -412,39 -403,6 +412,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -453,32 -411,7 +453,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -63,17 -63,8 +63,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>MAVEN_OPTS</name>
            <description>Maven Java opts. Example: -Xmx1024m -XX:MaxPermSize=256m
@@@ -370,39 -361,6 +370,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -411,32 -369,7 +411,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -63,17 -63,8 +63,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>MAVEN_OPTS</name>
            <description>Maven Java opts. Example: -Xmx1024m -XX:MaxPermSize=256m
@@@ -222,39 -213,6 +222,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -263,32 -221,7 +263,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -529,39 -462,6 +529,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -570,32 -470,7 +570,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -62,17 -62,8 +62,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>TOX_DIR</name>
            <description>Path to directory containing tox.ini file.
@@@ -199,39 -190,6 +199,39 @@@ Example: docs,py2,py
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -240,32 -198,7 +240,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -433,39 -366,6 +433,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -474,32 -374,7 +474,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -57,17 -57,8 +57,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>JJB_VERSION</name>
            <description>Jenkins Job Builder version to download and install.</description>
@@@ -309,39 -300,6 +309,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -350,32 -308,7 +350,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -57,17 -57,8 +57,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>JJB_VERSION</name>
            <description>Jenkins Job Builder version to download and install.</description>
@@@ -388,39 -379,6 +388,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -429,32 -387,7 +429,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -5,7 -5,7 +5,7 @@@
    <keepDependencies>false</keepDependencies>
    <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
    <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
-   <concurrentBuild>true</concurrentBuild>
+   <concurrentBuild>false</concurrentBuild>
    <assignedNode>build-vm</assignedNode>
    <canRoam>false</canRoam>
    <properties>
@@@ -57,17 -57,8 +57,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -482,39 -473,6 +482,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -523,32 -481,7 +523,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -5,7 -5,7 +5,7 @@@
    <keepDependencies>false</keepDependencies>
    <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
    <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
-   <concurrentBuild>true</concurrentBuild>
+   <concurrentBuild>false</concurrentBuild>
    <assignedNode>build-vm</assignedNode>
    <canRoam>false</canRoam>
    <properties>
@@@ -57,17 -57,8 +57,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -482,39 -473,6 +482,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -523,32 -481,7 +523,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -5,7 -5,7 +5,7 @@@
    <keepDependencies>false</keepDependencies>
    <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
    <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
-   <concurrentBuild>true</concurrentBuild>
+   <concurrentBuild>false</concurrentBuild>
    <assignedNode>build-vm</assignedNode>
    <canRoam>false</canRoam>
    <properties>
@@@ -57,17 -57,8 +57,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -482,39 -473,6 +482,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -523,32 -481,7 +523,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -5,7 -5,7 +5,7 @@@
    <keepDependencies>false</keepDependencies>
    <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
    <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
-   <concurrentBuild>true</concurrentBuild>
+   <concurrentBuild>false</concurrentBuild>
    <assignedNode>build-vm</assignedNode>
    <canRoam>false</canRoam>
    <properties>
@@@ -57,17 -57,8 +57,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -482,39 -473,6 +482,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -523,32 -481,7 +523,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -57,17 -57,8 +57,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>PACKER_VERSION</name>
            <description>Packer version to download and install.</description>
@@@ -356,39 -347,6 +356,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -397,32 -355,7 +397,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -58,17 -58,8 +58,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>MAVEN_OPTS</name>
            <description>Maven Java opts. Example: -Xmx1024m -XX:MaxPermSize=256m
@@@ -365,39 -356,6 +365,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -406,32 -364,7 +406,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -58,17 -58,8 +58,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>MAVEN_OPTS</name>
            <description>Maven Java opts. Example: -Xmx1024m -XX:MaxPermSize=256m
@@@ -217,39 -208,6 +217,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -258,32 -216,7 +258,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -524,39 -457,6 +524,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -565,32 -465,7 +565,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -57,17 -57,8 +57,17 @@@ job is triggered by Gerrit
  Note that Gerrit will override this parameter automatically if a
  job is triggered by Gerrit.
  </description>
-           <defaultValue/>
+           <defaultValue>refs/heads/master</defaultValue>
          </hudson.model.StringParameterDefinition>
 +        <hudson.model.StringParameterDefinition>
 +          <name>LFTOOLS_VERSION</name>
 +          <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 '&lt;1.0.0' or '&gt;=1.0.0,&lt;2.0.0'.
 +</description>
 +          <defaultValue>&lt;1.0.0</defaultValue>
 +        </hudson.model.StringParameterDefinition>
          <hudson.model.StringParameterDefinition>
            <name>TOX_DIR</name>
            <description>Path to directory containing tox.ini file.
@@@ -161,39 -152,6 +161,39 @@@ Example: docs,py2,py
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -202,32 -160,7 +202,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
@@@ -395,39 -328,6 +395,39 @@@ echo &quot;machine $machine login $use
  ##############################################################################
  echo &quot;---&gt; lftools-install.sh&quot;
  
 +# Script to install lftools via a version passed in via lf-infra-parameters
 +#
 +# Required parameters:
 +#
 +#     LFTOOLS_VERSION: Passed in via lf-infra-parameters configuration. Can be
 +#                      set to a strict version number like '1.2.3' or using
 +#                      PEP-440 definitions.
 +#
 +#                      Examples:
 +#                          &lt;1.0.0
 +#                          &gt;=1.0.0,&lt;2.0.0
 +#
 +# By default a released version of lftools should always be used.
 +# The purpose of the 2 variables below is so that lftools devs can test
 +# unreleased versions of lftools. There are 2 methods to install a dev version
 +# of lftools:
 +#
 +#     1) gerrit patch: Used to test a patch that has not yet been merged.
 +#                      To do this set something like this:
 +#                          LFTOOLS_MODE=gerrit
 +#                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
 +#
 +#     2) git branch: Used to install an lftools version from a specific branch.
 +#                    To use this set the variables as follows:
 +#                          LFTOOLS_MODE=git
 +#                          LFTOOLS_REFSPEC=master
 +#
 +#     3) release : The intended use case and default setting.
 +#                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
 +
 +LFTOOLS_MODE=release  # release | git | gerrit
 +LFTOOLS_REFSPEC=master
 +
  # Ensure we fail the job if any steps fail.
  # DO NOT set -u as virtualenv's activate script has unbound variables
  set -e -o pipefail
@@@ -436,32 -336,7 +436,32 @@@ virtualenv --quiet &quot;/tmp/v/lftools
  # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
  source &quot;/tmp/v/lftools/bin/activate&quot;
  pip install --quiet --upgrade pip
 -pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
 +
 +case $LFTOOLS_MODE in
 +    gerrit)
 +        git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
 +        pushd /tmp/lftools
 +        git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
 +        git checkout FETCH_HEAD
 +        pip install --quiet --upgrade -r requirements.txt
 +        pip install --quiet --upgrade -e .
 +        popd
 +        ;;
 +
 +    git)
 +        pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
 +        ;;
 +
 +    release)
 +        if [[ $LFTOOLS_VERSION =~ ^[0-9] ]]; then
 +            LFTOOLS_VERSION=&quot;==$LFTOOLS_VERSION&quot;
 +        fi
 +
 +        pip install --quiet --upgrade &quot;lftools${LFTOOLS_VERSION}&quot;
 +        ;;
 +esac
 +
 +lftools --version
  
  # pipdeptree prints out a lot of information because lftools pulls in many
  # dependencies. Let's only print it if we want to debug.
diff --combined jjb/lf-ci-jobs.yaml
  
  - lf_packer: &lf_packer_common
      name: lf-packer-common
-     # Adds wrappers and parameters sections common to packer jobs.
+     # Provide configuration common in packer jobs.
  
      ######################
      # Default parameters #
      ######################
  
+     branch: master
      build-timeout: 45
+     stream: master
+     submodule-recursive: true
      packer-cloud-settings: packer-cloud-env
  
-     wrappers:
-       - lf-infra-wrappers:
-           build-timeout: '{build-timeout}'
-           jenkins-ssh-credential: '{jenkins-ssh-credential}'
+     #####################
+     # Job Configuration #
+     #####################
+     project-type: freestyle
+     node: '{build-node}'
+     properties:
+       - lf-infra-properties:
+           project: '{project}'
+           build-days-to-keep: 7
  
      parameters:
        - lf-infra-parameters:
            project: '{project}'
            stream: '{stream}'
            branch: '{branch}'
 +          lftools-version: '{lftools-version}'
        - lf-infra-packer-parameters:
            packer-version: '{packer-version}'
  
+     wrappers:
+       - lf-infra-wrappers:
+           build-timeout: '{build-timeout}'
+           jenkins-ssh-credential: '{jenkins-ssh-credential}'
+     publishers:
+       - lf-infra-publish
  - parameter:
      name: lf-infra-jjb-parameters
      parameters:
            project: '{project}'
            stream: '{stream}'
            branch: '{branch}'
 +          lftools-version: '{lftools-version}'
        - lf-infra-jjb-parameters:
            jjb-version: '{jjb-version}'
  
  # Packer Merge #
  ################
  
- - lf_packer_merge_builders: &lf_packer_merge_builders
-     name: lf-packer-merge-builders
+ - lf_packer_merge: &lf_packer_merge
+     name: lf-packer-merge
  
-     # Adds builders section common to merge packer jobs.
-     # {packer-cloud-settings} is passed from the project, defines the managed
-     #                   file-id name created in Jenkins
-     #                   (default: packer-cloud-env)
-     # {packer-version}: is global defined in job group level, the version number
-     #                   can be updated to install the latest version of packer.
-     # {platforms}:      defines the packer platform file, passed from the project.
-     # {template}:       defines the packer template file, passed from the project.
+     # Packer Merge job runs `packer build` to build system images in the cloud.
+     #
+     # 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)
+     #     :mvn-settings: The name of settings file containing credentials for
+     #         the project.
+     #     :platforms: Platform or distribution to build. Typically json file
+     #         found in the packer/vars directory. (Example: centos)
+     #     :template: System template to build. Typically shell script found in
+     #         the packer/provision directory. (Example: java-builder)
+     #
+     # Optional parameters:
+     #
+     #     :branch: Git branch to fetch for the build. (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)
+     #     :packer-cloud-settings: Name of settings file containing credentials
+     #         for the cloud that packer will build on. (default: packer-cloud-env)
+     #     :packer-version: Version of packer to install / use in build. (default: 1.0.2)
+     #     :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)
+     #
+     #     :gerrit_verify_triggers: Override Gerrit Triggers.
+     #     :gerrit_trigger_file_paths: Override file paths which can be used to
+     #         filter which file modifications will trigger a build.
+     #         (default defined by lf_jjb_common)
+     ######################
+     # Default parameters #
+     ######################
+     gerrit_merge_triggers:
+       - change-merged-event
+       - comment-added-contains-event:
+           comment-contains-value: remerge$
+     #####################
+     # Job Configuration #
+     #####################
  
      builders:
        - lf-infra-packer-validate:
  - job-template:
      name: '{project-name}-packer-merge-{platforms}-{templates}'
      id: gerrit-packer-merge
-     concurrent: true
-     <<: *lf_jjb_common
-     # yamllint disable-line rule:key-duplicates
      <<: *lf_packer_common
      # yamllint disable-line rule:key-duplicates
-     <<: *lf_packer_merge_builders
-     ######################
-     # Default parameters #
-     ######################
+     <<: *lf_packer_merge
  
      git-url: '$GIT_URL/$GERRIT_PROJECT'
  
-     gerrit_merge_triggers:
-       - change-merged-event
-       - comment-added-contains-event:
-           comment-contains-value: remerge$
-     #####################
-     # Job Configuration #
-     #####################
      scm:
        - lf-infra-gerrit-scm:
            git-url: '{git-url}'
  - job-template:
      name: '{project-name}-packer-merge-{platforms}-{templates}'
      id: github-packer-merge
-     concurrent: true
-     <<: *lf_jjb_common
-     # yamllint disable-line rule:key-duplicates
      <<: *lf_packer_common
      # yamllint disable-line rule:key-duplicates
-     <<: *lf_packer_merge_builders
-     #####################
-     # Job Configuration #
-     #####################
+     <<: *lf_packer_merge
  
      properties:
        - github:
  # Packer Verify #
  #################
  
- - lf_packer_verify_builders: &lf_packer_verify_builders
-     name: lf-packer-verify-builders
-     # Adds builders section common to verify packer jobs.
-     # {packer-cloud-settings} is passed from the project, defines the managed
-     #                   file-id name created in Jenkins
-     #                   (default: packer-cloud-env)
-     # {packer-version}: is global defined in job group level, the version number
-     #                   can be updated to install the latest version of packer.
+ - lf_packer_verify: &lf_packer_verify
+     name: lf-packer-verify
  
-     builders:
-       - lf-infra-packer-validate:
-           packer-cloud-settings: '{packer-cloud-settings}'
-           packer-version: '{packer-version}'
- - job-template:
-     name: '{project-name}-packer-verify'
-     id: gerrit-packer-verify
-     concurrent: true
-     <<: *lf_jjb_common
-     # yamllint disable-line rule:key-duplicates
-     <<: *lf_packer_common
-     # yamllint disable-line rule:key-duplicates
-     <<: *lf_packer_verify_builders
+     # Packer Verify job runs `packer validate` to verify packer configuration.
+     #
+     # 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)
+     #     :mvn-settings: The name of settings file containing credentials for
+     #         the project.
+     #
+     # Optional parameters:
+     #
+     #     :branch: Git branch to fetch for the build. (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)
+     #     :packer-cloud-settings: Name of settings file containing credentials
+     #         for the cloud that packer will build on. (default: packer-cloud-env)
+     #     :packer-version: Version of packer to install / use in build. (default: 1.0.2)
+     #     :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)
+     #
+     #     :gerrit_verify_triggers: Override Gerrit Triggers.
+     #     :gerrit_trigger_file_paths: Override file paths which can be used to
+     #         filter which file modifications will trigger a build.
+     #         (default defined by lf_jjb_common)
  
      ######################
      # Default parameters #
      ######################
  
      build-timeout: 10
-     git-url: '$GIT_URL/$GERRIT_PROJECT'
  
      gerrit_verify_triggers:
        - patchset-created-event:
      # Job Configuration #
      #####################
  
+     concurrent: true
+     builders:
+       - lf-infra-packer-validate:
+           packer-cloud-settings: '{packer-cloud-settings}'
+           packer-version: '{packer-version}'
+ - job-template:
+     name: '{project-name}-packer-verify'
+     id: gerrit-packer-verify
+     <<: *lf_packer_common
+     # yamllint disable-line rule:key-duplicates
+     <<: *lf_packer_verify
+     git-url: '$GIT_URL/$GERRIT_PROJECT'
      scm:
        - lf-infra-gerrit-scm:
            git-url: '{git-url}'
  - job-template:
      name: '{project-name}-packer-verify'
      id: github-packer-verify
-     concurrent: true
-     <<: *lf_jjb_common
-     # yamllint disable-line rule:key-duplicates
      <<: *lf_packer_common
      # yamllint disable-line rule:key-duplicates
-     <<: *lf_packer_verify_builders
-     ######################
-     # Default parameters #
-     ######################
-     build-timeout: 10
-     #####################
-     # Job Configuration #
-     #####################
+     <<: *lf_packer_verify
  
      properties:
        - github:
diff --combined jjb/lf-macros.yaml
                job is triggered by Gerrit.
        - string:
            name: GERRIT_REFSPEC
-           default: ''
+           default: 'refs/heads/{branch}'
            description: |
                Parameter to identify a refspec when pulling from Gerrit.
  
                Note that Gerrit will override this parameter automatically if a
                job is triggered by Gerrit.
 -
 +      - 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-tox-parameters