Merge "Fix install_rally.sh to get it to work on MacOSX"

This commit is contained in:
Jenkins 2016-02-19 12:58:22 +00:00 committed by Gerrit Code Review
commit a8a9a78fe1

View File

@ -347,7 +347,7 @@ __EOF__
missing=${missing//python-pip/}
if ! $pkg_manager python-pip; then
if ask_yn "Error installing python-pip. Install from external source?"; then
local pdir=$(mktemp -d)
local pdir=$(mktemp /tmp/tmp.XXXXXXXXXX -d)
local getpip="$pdir/get-pip.py"
download "$getpip" https://bootstrap.pypa.io/get-pip.py
if ! "$PYTHON" "$getpip"; then
@ -460,7 +460,7 @@ setup_rally_configuration () {
cp "$SRCDIR"/etc/rally/rally.conf.sample "$ETCDIR"/rally.conf
[ -d "$DBDIR" ] || mkdir -p "$DBDIR"
local CONF_TMPFILE=$(mktemp)
local CONF_TMPFILE=$(mktemp /tmp/tmp.XXXXXXXXXX)
sed "s|#connection *=.*|connection = \"$DBCONNSTRING\"|" "$ETCDIR"/rally.conf > "$CONF_TMPFILE"
cat "$CONF_TMPFILE" > "$ETCDIR"/rally.conf
rm "$CONF_TMPFILE"