[LNT] r311501 - Make postgres database in a tmp dir
Chris Matthews via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 22 15:01:28 PDT 2017
Author: cmatthews
Date: Tue Aug 22 15:01:28 2017
New Revision: 311501
URL: http://llvm.org/viewvc/llvm-project?rev=311501&view=rev
Log:
Make postgres database in a tmp dir
The CI is failing because the path to the postgres database is longer
than postgres would like. Create the DB in a temp dir instead and delete
if the job passes.
Modified:
lnt/trunk/tests/SharedInputs/postgres_wrapper.sh
Modified: lnt/trunk/tests/SharedInputs/postgres_wrapper.sh
URL: http://llvm.org/viewvc/llvm-project/lnt/trunk/tests/SharedInputs/postgres_wrapper.sh?rev=311501&r1=311500&r2=311501&view=diff
==============================================================================
--- lnt/trunk/tests/SharedInputs/postgres_wrapper.sh (original)
+++ lnt/trunk/tests/SharedInputs/postgres_wrapper.sh Tue Aug 22 15:01:28 2017
@@ -9,7 +9,7 @@
# Inspired by https://github.com/tk0miya/testing.postgresql
set -u
-DBDIR="$1"
+DBDIR="$(mktemp -d -t lnt)"
shift
if [ -d "${DBDIR}" ]; then
echo 1>&2 "${DBDIR} already exists"
@@ -47,3 +47,4 @@ kill -15 $PG_PID
[ $? -ne 0 ] && (echo 1>&1 "Could not kill postgres server"; exit 1)
wait $PG_PID
exit $RC
+rm -rf ${DBDIR}
More information about the llvm-commits
mailing list