1--- a/bin/startup.sh
2+++ b/bin/startup.sh
3@@ -66,12 +66,9 @@ fi
4
5 #Find the configuration directory: GEOSERVER_DATA_DIR
6 if [ -z "${GEOSERVER_DATA_DIR:-}" ]; then
7- if [ -r "${GEOSERVER_HOME}/data_dir" ]; then
8- export GEOSERVER_DATA_DIR="${GEOSERVER_HOME}/data_dir"
9- else
10- echo "No GEOSERVER_DATA_DIR found, using application defaults"
11- GEOSERVER_DATA_DIR=""
12- fi
13+ echo "GEOSERVER_DATA_DIR is not provided. Using $(pwd)/geoserver/data_dir directory"
14+ mkdir -p "$(pwd)"/geoserver/data_dir
15+ GEOSERVER_DATA_DIR="$(pwd)/geoserver/data_dir"
16 fi
17
18 cd "${GEOSERVER_HOME}" || exit 1