Skip to content
This repository has been archived by the owner on Nov 8, 2019. It is now read-only.

Commit

Permalink
configure port to 1337
Browse files Browse the repository at this point in the history
  • Loading branch information
qzio committed Jul 20, 2011
1 parent 1cdf04d commit 1e9655b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
7 changes: 4 additions & 3 deletions bin/tscmd.sh
@@ -1,20 +1,21 @@
#!/bin/bash

PIDFILE=data/ts.pid
PORT=1337


case "$1" in
start)
echo "start tracking"
curl -X POST -F "cmd=start" localhost:4567/index.text
curl -X POST -F "cmd=start" localhost:$PORT/index.text
;;
stop)
echo "stop tracking"
curl -X POST -F "cmd=stop" localhost:4567/index.text
curl -X POST -F "cmd=stop" localhost:$PORT/index.text
;;
status)
echo "check status"
curl -X GET localhost:4567/index.text
curl -X GET localhost:$PORT/index.text
;;
startd)
echo "starting daemon"
Expand Down
4 changes: 4 additions & 0 deletions ts.rb
Expand Up @@ -8,6 +8,10 @@
Sinatra::Application.register Sinatra::RespondTo
set :haml, :format => :html5

configure do
set :port, 1337
end

get "/" do
redirect '/index'
end
Expand Down

0 comments on commit 1e9655b

Please sign in to comment.