init repo

This commit is contained in:
nikolay ivanov
2014-07-05 18:22:49 +00:00
commit a8be6b9e72
17348 changed files with 9229832 additions and 0 deletions

View File

@@ -0,0 +1,20 @@
ECHO OFF
SET DB_CONFIG_FILE=config_db.tmp
SET DB_NAME=coAuthoring
ECHO.
ECHO ----------------------------------------
ECHO Configure %DB_NAME% database
ECHO ----------------------------------------
ECHO db.createCollection("messages") > %DB_CONFIG_FILE%
ECHO db.messages.ensureIndex({"docid":1}) >> %DB_CONFIG_FILE%
ECHO db.createCollection("changes") >> %DB_CONFIG_FILE%
ECHO db.changes.ensureIndex({"docid":1}) >> %DB_CONFIG_FILE%
ECHO exit >> %DB_CONFIG_FILE%
call %~dp0..\mongodb\bin\mongo.exe %DB_NAME% < %DB_CONFIG_FILE% || exit /b 1
DEL /Q %DB_CONFIG_FILE%
exit /b 0

View File

@@ -0,0 +1,22 @@
ECHO OFF
SET RUN_FOLDER=%CD%
CD /D %~dp0..\ || exit /b 1
ECHO.
ECHO ----------------------------------------
ECHO Install node.js modules
ECHO ----------------------------------------
call npm install express@3.4.8 --production || exit /b 1
call npm install underscore@1.5.2 --production || exit /b 1
call npm install sockjs@0.3.8 --production|| exit /b 1
call npm install mongodb@1.1.4 --production || exit /b 1
cd /D ..\Common || exit /b 1
call npm install log4js@0.6.2 --production || exit /b 1
CD /D %RUN_FOLDER% || exit /b 1
exit /b 0

View File

@@ -0,0 +1,5 @@
SET DB_FILE_PATH=..\data\db
IF NOT EXIST %DB_FILE_PATH% MKDIR %DB_FILE_PATH%
call ..\mongodb\bin\mongod.exe --journal --dbpath "%DB_FILE_PATH%"
pause

View File

@@ -0,0 +1,2 @@
call node --debug ../sources/server.js
pause