diff options
Diffstat (limited to 'clustercontroller-standalone/src/main/sh/fleetcontroller-start')
-rwxr-xr-x | clustercontroller-standalone/src/main/sh/fleetcontroller-start | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/clustercontroller-standalone/src/main/sh/fleetcontroller-start b/clustercontroller-standalone/src/main/sh/fleetcontroller-start index 0cf0a9b0f88..85cf698148e 100755 --- a/clustercontroller-standalone/src/main/sh/fleetcontroller-start +++ b/clustercontroller-standalone/src/main/sh/fleetcontroller-start @@ -56,9 +56,12 @@ findroot () { findhost () { if [ "${VESPA_HOSTNAME}" = "" ]; then - VESPA_HOSTNAME=$(vespa-detect-hostname) || exit 1 + VESPA_HOSTNAME=$(vespa-detect-hostname || hostname -f || hostname || echo "localhost") || exit 1 + fi + validate="${VESPA_HOME}/bin/vespa-validate-hostname" + if [ -f "$validate" ]; then + "$validate" "${VESPA_HOSTNAME}" || exit 1 fi - vespa-validate-hostname "${VESPA_HOSTNAME}" || exit 1 export VESPA_HOSTNAME } |