| 1 | #!/usr/bin/env sh |
| 2 | |
| 3 | if ! gem list foreman -i --silent; then |
| 4 | echo "Installing foreman..." |
| 5 | gem install foreman |
| 6 | fi |
| 7 | |
| 8 | # Default to port 3000 if not specified |
| 9 | export PORT="${PORT:-3000}" |
| 10 | |
| 11 | # Let the debug gem allow remote connections, |
| 12 | # but avoid loading until `debugger` is called |
| 13 | export RUBY_DEBUG_OPEN="true" |
| 14 | export RUBY_DEBUG_LAZY="true" |
| 15 | |
| 16 | exec foreman start -f Procfile.dev "$@" |