Prepare for using standard py27 test
Instead of setting up spark in the CI job, move the set up here so that it can be reused by other jobs as well. Create a test-setup.sh script that developer can also use to setup their own environment. This makes it easier for monasca-analytics to change the setup, documents the setup, and enables developer to reuse it. For details see: http://lists.openstack.org/pipermail/openstack-dev/2016-November/107784.html Change-Id: Id1a0b8d44d5a258746dd1f443610293163e64096 Needed-By: I0fdce1a977f59cdcb8c63c2b215316cbfcf4fef4
This commit is contained in:
parent
2861f29bfe
commit
2d16acee4f
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash -xe
|
||||
|
||||
# This script will be run by OpenStack CI before unit tests are run,
|
||||
# it sets up the test system as needed.
|
||||
# Developers should setup their test systems in a similar way.
|
||||
|
||||
HOME=${{HOME:-/home/jenkins}}
|
||||
SPARK_DIR=$HOME/spark
|
||||
SPARK_VERSION=${{SPARK_VERSION:-1.6.1}}
|
||||
SPARK_TARBALL_NAME=spark-$SPARK_VERSION.tgz
|
||||
SPARK_URL=http://archive.apache.org/dist/spark/spark-$SPARK_VERSION/$SPARK_TARBALL_NAME
|
||||
|
||||
mkdir -p $SPARK_DIR
|
||||
curl $SPARK_URL -o $SPARK_DIR/$SPARK_TARBALL_NAME
|
||||
tar -xzf $SPARK_DIR/$SPARK_TARBALL_NAME -C $SPARK_DIR
|
Loading…
Reference in New Issue