You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: scripts/setupNeo4j.sh
+35-15Lines changed: 35 additions & 15 deletions
Original file line number
Diff line number
Diff line change
@@ -7,6 +7,8 @@
7
7
NEO4J_EDITION=${NEO4J_EDITION:-"community"}# Choose "community" or "enterprise"
8
8
NEO4J_VERSION=${NEO4J_VERSION:-"4.4.20"}# Version 4.4.x is the current long term support (LTS) version (april 2023)
9
9
NEO4J_APOC_PLUGIN_VERSION=${NEO4J_APOC_PLUGIN_VERSION:-"4.4.0.15"}#Awesome Procedures for Neo4j Plugin Version 4.4.0.x of is compatible with Neo4j 4.4.x
## Get this "scripts" directory if not already set
19
19
# Even if $BASH_SOURCE is made for Bourne-like shells it is also supported by others and therefore here the preferred solution.
@@ -37,7 +37,7 @@ else
37
37
fi
38
38
39
39
# Check if Neo4j is stopped (not running) using a temporary NEO4J_HOME environment variable that points to the current installation
40
-
if NEO4J_HOME=${NEO4J_DIR}${NEO4J_BIN}/neo4j status | grep -q "not";then
40
+
if NEO4J_HOME=${NEO4J_DIR}${NEO4J_BIN}/neo4j status 2>&1| grep -q "not running";then
41
41
echo"startNeo4j: Starting neo4j-${NEO4J_EDITION}-${NEO4J_VERSION} in ${NEO4J_DIR}"
42
42
43
43
# Check if there is already a process that listens to the Neo4j HTTP port
@@ -57,7 +57,7 @@ if NEO4J_HOME=${NEO4J_DIR} ${NEO4J_BIN}/neo4j status | grep -q "not" ; then
57
57
echo"startNeo4j: Waiting for ${waitTime} second(s)"
58
58
sleep ${waitTime}
59
59
60
-
if! NEO4J_HOME=${NEO4J_DIR}${NEO4J_BIN}/neo4j status | grep -q "not";then
60
+
if! NEO4J_HOME=${NEO4J_DIR}${NEO4J_BIN}/neo4j status 2>&1| grep -q "not running";then
61
61
echo"startNeo4j: Successfully started neo4j-${NEO4J_EDITION}-${NEO4J_VERSION}"
62
62
exit 0
63
63
fi
@@ -67,7 +67,7 @@ else
67
67
fi
68
68
69
69
# Check if Neo4j is still not running using a temporary NEO4J_HOME environment variable that points to the current installation
70
-
if NEO4J_HOME=${NEO4J_DIR}${NEO4J_BIN}/neo4j status | grep -q "not";then
70
+
if NEO4J_HOME=${NEO4J_DIR}${NEO4J_BIN}/neo4j status 2>&1| grep -q "not running";then
71
71
echo"startNeo4j: neo4j-${NEO4J_EDITION}-${NEO4J_VERSION} still not running. Something went wrong. Details see 'NEO4J_HOME=${NEO4J_DIR}${NEO4J_BIN}/neo4j status'."
echo"stopNeo4j: neo4j-${NEO4J_EDITION}-${NEO4J_VERSION} still running. Something went wrong. Details see 'NEO4J_HOME=${NEO4J_DIR}${NEO4J_BIN}/neo4j status'."
0 commit comments