mirror of
https://github.com/elastic/kibana.git
synced 2025-04-19 15:35:00 -04:00
Using the --dev flag is the only support way to change the internal Kibana environment to something else. Allowing NODE_ENV to be set at all can have unexpected results with our dependencies, so we now always set it to production.
31 lines
507 B
Batchfile
31 lines
507 B
Batchfile
@echo off
|
|
|
|
SETLOCAL
|
|
|
|
set SCRIPT_DIR=%~dp0
|
|
for %%I in ("%SCRIPT_DIR%..") do set DIR=%%~dpfI
|
|
|
|
set NODE=%DIR%\node\node.exe
|
|
|
|
set NODE_ENV="production"
|
|
|
|
WHERE /Q node
|
|
IF %ERRORLEVEL% EQU 0 (
|
|
for /f "delims=" %%i in ('WHERE node') do set SYS_NODE=%%i
|
|
)
|
|
|
|
If Not Exist "%NODE%" (
|
|
IF Exist "%SYS_NODE%" (
|
|
set "NODE=%SYS_NODE%"
|
|
) else (
|
|
Echo unable to find usable node.js executable.
|
|
Exit /B 1
|
|
)
|
|
)
|
|
|
|
TITLE Kibana Server
|
|
"%NODE%" %NODE_OPTIONS% --no-warnings "%DIR%\src\cli" %*
|
|
|
|
:finally
|
|
|
|
ENDLOCAL
|