Merge "Add puppet-verify job to lf-ci-jobs"
[releng/global-jjb.git] / shell / python-tools-install.sh
1 #!/bin/bash -l
2 # SPDX-License-Identifier: EPL-1.0
3 ##############################################################################
4 # Copyright (c) 2018 The Linux Foundation and others.
5 #
6 # All rights reserved. This program and the accompanying materials
7 # are made available under the terms of the Eclipse Public License v1.0
8 # which accompanies this distribution, and is available at
9 # http://www.eclipse.org/legal/epl-v10.html
10 ##############################################################################
11
12 set -eux -o pipefail
13
14 REQUIREMENTS_FILE=$(mktemp /tmp/requirements-XXXX.txt)
15
16 # Note: To test lftools master branch change the lftools configuration below in
17 #       the requirements file from "lftools[openstack]~=#.##.#" to
18 #       git+https://github.com/lfit/releng-lftools.git#egg=lftools[openstack]
19
20 cat << EOF > "$REQUIREMENTS_FILE"
21 lftools[openstack]~=0.18.0
22 python-heatclient~=1.16.1
23 python-openstackclient~=3.16.0
24 dogpile.cache~=0.6.8  # Version 0.7.[01] seems to break openstackclient
25 EOF
26
27 echo "Requirements file"
28 echo "-----------------"
29 cat "$REQUIREMENTS_FILE"
30
31 # Use `python -m pip` to ensure we are using the latest version of pip
32 python -m pip install --user --quiet --upgrade pip
33 python -m pip install --user --quiet --upgrade setuptools
34 python -m pip install --user --quiet --upgrade -r "$REQUIREMENTS_FILE"
35 pip freeze