Adding bat and shell scripts for starting the node server
This commit is contained in:
parent
9e28e8bdbd
commit
a7cb09a028
2 changed files with 41 additions and 0 deletions
|
@ -0,0 +1,20 @@
|
||||||
|
@echo off
|
||||||
|
|
||||||
|
SETLOCAL
|
||||||
|
|
||||||
|
set SCRIPT_DIR=%~dp0
|
||||||
|
for %%I in ("%SCRIPT_DIR%..") do set DIR=%%~dpfI
|
||||||
|
|
||||||
|
set NODE=%FULL_PATH%\node\node.exe
|
||||||
|
set SERVER=%DIR%/src/bin/kibana.js
|
||||||
|
set NODE_ENV="production"
|
||||||
|
|
||||||
|
TITLE Kibana Server @@version
|
||||||
|
|
||||||
|
%NODE% %SERVER%
|
||||||
|
|
||||||
|
:finally
|
||||||
|
|
||||||
|
ENDLOCAL
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,21 @@
|
||||||
|
#!/bin/sh
|
||||||
|
SCRIPT=$0
|
||||||
|
|
||||||
|
# SCRIPT may be an arbitrarily deep series of symlinks. Loop until we have the concrete path.
|
||||||
|
while [ -h "$SCRIPT" ] ; do
|
||||||
|
ls=$(ls -ld "$SCRIPT")
|
||||||
|
# Drop everything prior to ->
|
||||||
|
link=$(expr "$ls" : '.*-> \(.*\)$')
|
||||||
|
if expr "$link" : '/.*' > /dev/null; then
|
||||||
|
SCRIPT="$link"
|
||||||
|
else
|
||||||
|
SCRIPT=$(dirname "$SCRIPT")/"$link"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
DIR=$(dirname "${SCRIPT}")/..
|
||||||
|
NODE=${DIR}/node/bin/node
|
||||||
|
SERVER=${DIR}/src/bin/kibana.js
|
||||||
|
|
||||||
|
NODE_ENV="production" exec "${NODE}" ${SERVER}
|
||||||
|
|
Loading…
Reference in a new issue