14 lines
332 B
Bash
14 lines
332 B
Bash
#/bin/bash
|
|
rails_env=$1
|
|
if [ -z $rails_env ]; then
|
|
rails_env=development
|
|
fi
|
|
daemon_args=""
|
|
if [[ "$2" != "-ND" ]]; then
|
|
daemon_args="-D"
|
|
fi
|
|
if [ -z "$4" ]; then
|
|
bundle exec unicorn_rails -c config/unicorn.rb -E $rails_env $daemon_args $3
|
|
else
|
|
bundle exec unicorn_rails -c config/unicorn.rb -E $rails_env $daemon_args $3 "$4"
|
|
fi |