Skip to content

Commit 5824542

Browse files
authored
Merge pull request #1917 from tuxillo/master
Introduce OPENGROK_DATA_ROOT for better customization
2 parents 27d0b26 + ee155ad commit 5824542

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

OpenGrok

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
# - OPENGROK_DISTRIBUTION_BASE Base Directory of the OpenGrok Distribution
3939
# - OPENGROK_INSTANCE_BASE Base Directory of the OpenGrok User Data Area
4040
# - OPENGROK_SRC_ROOT directory with files to be indexed
41+
# - OPENGROK_DATA_ROOT directory where index and cache files are generated
4142
# - OPENGROK_CTAGS Full path to Exuberant or Universal CTags binary
4243
# - OPENGROK_CTAGS_OPTIONS_FILE Full path to file with extra command line
4344
# options for CTags program (for its --options
@@ -223,7 +224,11 @@ DefaultInstanceConfiguration()
223224
# REQUIRED: OpenGrok Generate Data Root
224225
# (for Lucene index and hypertext cross-references)
225226
# This area is rebuilt by "update" / "updateQuietly"
226-
DATA_ROOT="${OPENGROK_INSTANCE_BASE}/data"
227+
if [ -n "${OPENGROK_DATA_ROOT}" ]; then
228+
DATA_ROOT="${OPENGROK_DATA_ROOT}"
229+
else
230+
DATA_ROOT="${OPENGROK_INSTANCE_BASE}/data"
231+
fi
227232

228233
# OPTIONAL: User Provided Source Path to Description Mapping
229234
# (Tab Separated Value)

0 commit comments

Comments
 (0)