Skip to content

Commit 535541b

Browse files
committed
try other travisCI repository
1 parent de94bb2 commit 535541b

File tree

1 file changed

+59
-61
lines changed

1 file changed

+59
-61
lines changed

tests/travis/setup_arangodb.sh

Lines changed: 59 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -1,65 +1,63 @@
11
#!/bin/bash
22

33
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
4-
cd $DIR
5-
6-
VERSION=1.4.0-beta2
7-
NAME=ArangoDB-$VERSION
8-
9-
if [ ! -d "$DIR/$NAME" ]; then
10-
# download ArangoDB
11-
echo "wget http://www.arangodb.org/travisCI/$NAME.tar.gz"
12-
wget http://www.arangodb.org/travisCI/$NAME.tar.gz
13-
echo "tar zxf $NAME.tar.gz"
14-
tar zvxf $NAME.tar.gz
15-
fi
16-
17-
ARCH=$(arch)
18-
PID=$(echo $PPID)
19-
TMP_DIR="/tmp/arangodb.$PID"
20-
PID_FILE="/tmp/arangodb.$PID.pid"
21-
ARANGODB_DIR="$DIR/$NAME"
22-
23-
ARANGOD="${ARANGODB_DIR}/bin/arangod"
24-
if [ "$ARCH" == "x86_64" ]; then
4+
cd $DIR
5+
6+
VERSION=1.4.0
7+
NAME=ArangoDB-$VERSION
8+
9+
if [ ! -d "$DIR/$NAME" ]; then
10+
# download ArangoDB
11+
echo "wget http://www.arangodb.org/repositories/travisCI/$NAME.tar.gz"
12+
wget http://www.arangodb.org/repositories/travisCI/$NAME.tar.gz
13+
echo "tar zxf $NAME.tar.gz"
14+
tar zvxf $NAME.tar.gz
15+
fi
16+
17+
ARCH=$(arch)
18+
PID=$(echo $PPID)
19+
TMP_DIR="/tmp/arangodb.$PID"
20+
PID_FILE="/tmp/arangodb.$PID.pid"
21+
ARANGODB_DIR="$DIR/$NAME"
22+
23+
ARANGOD="${ARANGODB_DIR}/bin/arangod"
24+
if [ "$ARCH" == "x86_64" ]; then
2525
ARANGOD="${ARANGOD}_x86_64"
26-
fi
27-
28-
# create database directory
29-
mkdir ${TMP_DIR}
30-
31-
echo "Starting ArangoDB '${ARANGOD}'"
32-
33-
${ARANGOD} \
34-
--database.directory ${TMP_DIR} \
35-
--configuration none \
36-
--server.endpoint tcp://127.0.0.1:8529 \
37-
--javascript.startup-directory ${ARANGODB_DIR}/js \
38-
--server.admin-directory ${ARANGODB_DIR}/html/admin \
39-
--javascript.modules-path ${ARANGODB_DIR}/js/server/modules:${ARANGODB_DIR}/js/common/modules:${ARANGODB_DIR}/js/node \
40-
--javascript.package-path ${ARANGODB_DIR}/js/npm:${ARANGODB_DIR}/js/common/test-data/modules \
41-
--javascript.app-path ${ARANGODB_DIR}/js/apps \
42-
--javascript.action-directory ${ARANGODB_DIR}/js/actions \
43-
--database.maximal-journal-size 1048576 \
44-
--server.disable-admin-interface true \
45-
--server.disable-authentication true \
46-
--javascript.gc-interval 1 &
47-
48-
sleep 2
49-
50-
echo "Check for arangod process"
51-
process=$(ps auxww | grep "bin/arangod" | grep -v grep)
52-
53-
if [ "x$process" == "x" ]; then
54-
echo "no 'arangod' process found"
55-
echo "ARCH = $ARCH"
56-
exit 1
57-
fi
58-
59-
echo "Waiting until ArangoDB is ready on port 8529"
60-
while [[ -z `curl -s 'http://127.0.0.1:8529/_api/version' ` ]] ; do
61-
echo -n "."
62-
sleep 2s
63-
done
64-
65-
echo "ArangoDB is up"
26+
fi
27+
28+
# create database directory
29+
mkdir ${TMP_DIR}
30+
31+
echo "Starting ArangoDB '${ARANGOD}'"
32+
33+
${ARANGOD} \
34+
--database.directory ${TMP_DIR} \
35+
--configuration none \
36+
--server.endpoint tcp://127.0.0.1:8529 \
37+
--javascript.startup-directory ${ARANGODB_DIR}/js \
38+
--javascript.modules-path ${ARANGODB_DIR}/js/server/modules:${ARANGODB_DIR}/js/common/modules:${ARANGODB_DIR}/js/node \
39+
--javascript.package-path ${ARANGODB_DIR}/js/npm:${ARANGODB_DIR}/js/common/test-data/modules \
40+
--javascript.app-path ${ARANGODB_DIR}/js/apps \
41+
--javascript.action-directory ${ARANGODB_DIR}/js/actions \
42+
--database.maximal-journal-size 1048576 \
43+
--server.disable-authentication true \
44+
--javascript.gc-interval 1 &
45+
46+
sleep 2
47+
48+
echo "Check for arangod process"
49+
process=$(ps auxww | grep "bin/arangod" | grep -v grep)
50+
51+
if [ "x$process" == "x" ]; then
52+
echo "no 'arangod' process found"
53+
echo "ARCH = $ARCH"
54+
exit 1
55+
fi
56+
57+
echo "Waiting until ArangoDB is ready on port 8529"
58+
while [[ -z `curl -s 'http://127.0.0.1:8529/_api/version' ` ]] ; do
59+
echo -n "."
60+
sleep 2s
61+
done
62+
63+
echo "ArangoDB is up"

0 commit comments

Comments
 (0)