summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authormokha <mokha@cisco.com>2019-01-29 08:49:43 -0700
committermokha <mokha@cisco.com>2019-01-29 08:49:43 -0700
commit70c09f472d7b996dfc11dac4bc3950351ef0e08d (patch)
treea1dcbd640b0c73646da2831c24bd54eeac732c64 /bin
parent35858253e869bd5b05dcf6b9483e85db700524b5 (diff)
start server using foreman
Diffstat (limited to 'bin')
-rwxr-xr-xbin/server16
1 files changed, 15 insertions, 1 deletions
diff --git a/bin/server b/bin/server
index 555f067..28104ed 100755
--- a/bin/server
+++ b/bin/server
@@ -1,3 +1,17 @@
#!/bin/sh
-bin/rails server
+# bin/server: Launch the application and any extra required processes locally.
+
+set -e
+cd "$(dirname "$0")/.."
+
+PORT=${PORT:=4000}
+PROCFILE=Procfile
+
+export PORT
+
+test -z "$RACK_ENV" && RACK_ENV='development'
+bin/update
+
+gem install foreman
+foreman start -e /dev/null -f $PROCFILE