Skip to content

Commit 0b10b95

Browse files
author
Paul Korzhyk
committed
2 parents 4b304e8 + 7202c9d commit 0b10b95

File tree

4 files changed

+13
-6
lines changed

4 files changed

+13
-6
lines changed

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,3 +35,7 @@ coverage/
3535
# Misc
3636
.DS_Store
3737
Thumbs.db
38+
39+
# Dgraph
40+
41+
data/**

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
language: node_js
22
node_js:
3-
- "node"
4-
- "8"
3+
- "node"
4+
- "8"
55
sudo: required
66
dist: trusty
77
before_install:

scripts/build.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ init
99
startZero
1010
start
1111

12+
sleep 10 # Dgraph need some time to create Groot user
13+
1214
npm run build
1315
npm test
1416

scripts/functions.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@ fi
77

88
function quit {
99
echo "Shutting down Dgraph alpha and zero."
10-
curl -s localhost:8080/admin/shutdown
11-
# Kill Dgraph zero.
12-
kill -9 $(pgrep -f "dgraph zero") > /dev/null
10+
curl -s localhost:8080/admin/shutdown #TODO In the future this endpoint won't work anymore, in favor of GraphQL. We should prepare it.
11+
12+
kill -9 $(pgrep -f "dgraph zero") > /dev/null # Kill Dgraph zero.
13+
kill -9 $(pgrep -f "dgraph alpha") > /dev/null # I don't wanna wait "clean shutdown" on this context. Let's kill it please...
1314

1415
if pgrep -x dgraph > /dev/null
1516
then
@@ -24,7 +25,7 @@ function quit {
2425
function start {
2526
echo -e "Starting Dgraph alpha."
2627
head -c 1024 /dev/random > data/acl-secret.txt
27-
dgraph alpha -p data/p -w data/w --lru_mb 4096 --zero localhost:5080 --acl_secret_file data/acl-secret.txt > data/server.log 2>&1 &
28+
dgraph alpha -p data/p -w data/w --lru_mb 4096 --acl_secret_file data/acl-secret.txt > data/alpha.log 2>&1 &
2829
# Wait for membership sync to happen.
2930
sleep $sleepTime
3031
return 0

0 commit comments

Comments
 (0)