--- sbin/rabbitmq-defaults.orig	2024-02-17 11:42:49 UTC
+++ sbin/rabbitmq-defaults
@@ -7,7 +7,13 @@
 ##
 
 ### next line potentially updated in package install steps
-SYS_PREFIX=${RABBITMQ_HOME}
+SYS_PREFIX=LOCALBASE
+# https://www.rabbitmq.com/relocate.html#unix
+export PATH=LOCALBASE/lib/_ERLANG_LIB/bin:$PATH
+export RABBITMQ_MNESIA_BASE=/var/db/rabbitmq/mnesia
+export RABBITMQ_LOG_BASE=/var/log/rabbitmq
+# ensure VM and Elixir scripts are running under the same locale
+export LANG=en_US.UTF-8
 
 CLEAN_BOOT_FILE=start_clean
 SASL_BOOT_FILE=start_sasl
