Skip to content

Commit

Permalink
Auto restarting shell script
Browse files Browse the repository at this point in the history
  • Loading branch information
Graham Tackley committed Dec 19, 2011
1 parent 8952692 commit cc3f9a2
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
4 changes: 2 additions & 2 deletions readme.md
Expand Up @@ -34,9 +34,9 @@ We use [Foreman](https://github.com/ddollar/foreman) to startup all the apps, so

Then startup with:

foreman start
./start.sh

Now go to http://localhost:5000 and enjoy.
Which will run foreman start in an infinite loop. Now go to http://localhost:5000 and enjoy.



Expand Down
8 changes: 8 additions & 0 deletions start.sh
@@ -0,0 +1,8 @@
#!/bin/bash

while true; do
foreman start
echo "Foreman exited with code $?. Respawning... (hit ^C again now to stop!)" >&2
sleep 5
done

0 comments on commit cc3f9a2

Please sign in to comment.