#!/bin/sh -e
##  This Source Code Form is subject to the terms of the Mozilla Public
##  License, v. 2.0. If a copy of the MPL was not distributed with this
##  file, You can obtain one at https://mozilla.org/MPL/2.0/.
##
##  Copyright (c) 2007-2024 Broadcom. All Rights Reserved. The term “Broadcom” refers to Broadcom Inc. and/or its subsidiaries. All rights reserved.
##

### next line potentially updated in package install steps
SYS_PREFIX=/usr/local
# https://www.rabbitmq.com/relocate.html#unix
export PATH=/usr/local/lib/erlang27/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
BOOT_MODULE="rabbit"

if test -z "$CONF_ENV_FILE" && test -z "$RABBITMQ_CONF_ENV_FILE"; then
    CONF_ENV_FILE=${SYS_PREFIX}/etc/rabbitmq/rabbitmq-env.conf
fi
