diff options
| author | Paul Jones <pauljones23@gmail.com> | 2009-07-22 15:48:50 +0100 |
|---|---|---|
| committer | Paul Jones <pauljones23@gmail.com> | 2009-07-22 15:48:50 +0100 |
| commit | c0d98e1713f9e21c9e03615ef24dec6cc0d11639 (patch) | |
| tree | b6e8d889fc1126e665e8c7cc144a79b1b51dfb68 /scripts | |
| parent | 1a3b107a92397fdf60ed370ad11877024922c2c0 (diff) | |
| download | rabbitmq-server-git-c0d98e1713f9e21c9e03615ef24dec6cc0d11639.tar.gz | |
Added a rabbit_plugin_activator to generate a .boot file for Rabbit; changed startup script to use this file if available
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/activate-plugins | 46 | ||||
| -rwxr-xr-x | scripts/rabbitmq-server | 8 |
2 files changed, 53 insertions, 1 deletions
diff --git a/scripts/activate-plugins b/scripts/activate-plugins new file mode 100755 index 0000000000..daa5e99fef --- /dev/null +++ b/scripts/activate-plugins @@ -0,0 +1,46 @@ +#!/bin/sh +## The contents of this file are subject to the Mozilla Public License +## Version 1.1 (the "License"); you may not use this file except in +## compliance with the License. You may obtain a copy of the License at +## http://www.mozilla.org/MPL/ +## +## Software distributed under the License is distributed on an "AS IS" +## basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the +## License for the specific language governing rights and limitations +## under the License. +## +## The Original Code is RabbitMQ. +## +## The Initial Developers of the Original Code are LShift Ltd, +## Cohesive Financial Technologies LLC, and Rabbit Technologies Ltd. +## +## Portions created before 22-Nov-2008 00:00:00 GMT by LShift Ltd, +## Cohesive Financial Technologies LLC, or Rabbit Technologies Ltd +## are Copyright (C) 2007-2008 LShift Ltd, Cohesive Financial +## Technologies LLC, and Rabbit Technologies Ltd. +## +## Portions created by LShift Ltd are Copyright (C) 2007-2009 LShift +## Ltd. Portions created by Cohesive Financial Technologies LLC are +## Copyright (C) 2007-2009 Cohesive Financial Technologies +## LLC. Portions created by Rabbit Technologies Ltd are Copyright +## (C) 2007-2009 Rabbit Technologies Ltd. +## +## All Rights Reserved. +## +## Contributor(s): ______________________________________. +## + +[ -f /etc/rabbitmq/rabbitmq.conf ] && . /etc/rabbitmq/rabbitmq.conf + +[ "x" = "x$RABBITMQ_PLUGINS_DIR" ] && RABBITMQ_PLUGINS_DIR="`dirname $0`/../plugins" +[ "x" = "x$RABBITMQ_PLUGINS_EXPAND_DIR" ] && RABBITMQ_PLUGINS_EXPAND_DIR="`dirname $0`/../priv/plugins" + +exec erl \ + -pa "`dirname $0`/../ebin" \ + -rabbit plugins_dir "\"$RABBITMQ_PLUGINS_DIR\"" \ + -rabbit plugins_expand_dir "\"$RABBITMQ_PLUGINS_EXPAND_DIR\"" \ + -rabbit rabbit_ebin "\"`dirname $0`/../ebin\"" \ + -noinput \ + -hidden \ + -s rabbit_plugin_activator \ + -extra "$@" diff --git a/scripts/rabbitmq-server b/scripts/rabbitmq-server index 8502d60abc..40d664113e 100755 --- a/scripts/rabbitmq-server +++ b/scripts/rabbitmq-server @@ -75,6 +75,12 @@ fi RABBITMQ_START_RABBIT= [ "x" = "x$RABBITMQ_NODE_ONLY" ] && RABBITMQ_START_RABBIT='-noinput -s rabbit' +if [ -f "`dirname $0`/../ebin/rabbit.boot" ]; then + RABBITMQ_BOOT_FILE="`dirname $0`/../ebin/rabbit" +else + RABBITMQ_BOOT_FILE=start_sasl +fi + # we need to turn off path expansion because some of the vars, notably # RABBITMQ_SERVER_ERL_ARGS, contain terms that look like globs and # there is no other way of preventing their expansion. @@ -84,7 +90,7 @@ exec erl \ -pa "`dirname $0`/../ebin" \ ${RABBITMQ_START_RABBIT} \ -sname ${RABBITMQ_NODENAME} \ - -boot start_sasl \ + -boot $RABBITMQ_BOOT_FILE \ +W w \ ${RABBITMQ_SERVER_ERL_ARGS} \ -rabbit tcp_listeners '[{"'${RABBITMQ_NODE_IP_ADDRESS}'", '${RABBITMQ_NODE_PORT}'}]' \ |
