2013-01-04 04:45:47 +00:00
|
|
|
#!/bin/bash -l
|
|
|
|
|
|
|
|
|
|
# default config values
|
|
|
|
|
BUILD_NUMBER=1
|
|
|
|
|
|
|
|
|
|
CONFIG_FILE="/etc/websocket-gateway/upstart.conf"
|
|
|
|
|
if [ -e "$CONFIG_FILE" ]; then
|
|
|
|
|
. "$CONFIG_FILE"
|
|
|
|
|
fi
|
|
|
|
|
|
2013-01-17 04:40:42 +00:00
|
|
|
# I don't like doing this, but the next command (bundle exec) retouches/generates
|
|
|
|
|
# the gemfile. This unfortunately means the next debian update doesn't update this file.
|
|
|
|
|
# Ultimately this means an old Gemfile.lock is left behind for a new package,
|
|
|
|
|
# and bundle won't run because it thinks it has the wrong versions of gems
|
2013-01-17 04:51:04 +00:00
|
|
|
rm -f Gemfile.lock
|
2013-01-17 04:40:42 +00:00
|
|
|
|
2013-01-05 13:56:16 +00:00
|
|
|
BUILD_NUMBER=$BUILD_NUMBER JAMENV=production exec bundle exec ruby -Ilib bin/websocket_gateway
|