Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CTRL+C won't stop a sinatra app

Normally when I run a rails app from the console during development I can just press Ctrl + C and it exits. Then I can run the app again, thus bouncing it and effecting changes.

I am running a sinatra app. I just run the ruby file.

$: ruby myapp.rb

When I press Ctrl+C, however, it won't stop the app. I've had to bring up the Ubuntu System Monitor and kill the Ruby process. Very annoying.

Anyone seen this/dealt with this before?

like image 269
Mario Avatar asked Nov 04 '22 22:11

Mario


1 Answers

I installed the 'thin' gem and it works fine.

Apparently sinatra + Webrick is unstoppable.

(Also, running Ubuntu 11.04.)

like image 133
Mario Avatar answered Nov 09 '22 06:11

Mario