From a197c7d46d995b27a687dd554fb9e0576f31eac3 Mon Sep 17 00:00:00 2001 From: Fengda HUANG Date: Mon, 31 Aug 2015 08:41:00 +0800 Subject: [PATCH] Update README.md --- README.md | 27 +++++++++++++++++++-------- config/default.json | 2 +- server/index.js | 1 - 3 files changed, 20 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 444851c..66c4191 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ Test on Node Version: ``0.12.7`` ##Configure -Current Default Config: +Default Config: ```javascript { @@ -40,10 +40,13 @@ Current Default Config: "coap": 5683, "mqtt": 1883 }, - "logging" :false + "logging" :true, + "secret": "keyboard cat" } ``` +###**Import** make sure change secret + encrypt: ["crypto", "bcrypt"] modules: ["coap", "http", "mqtt", "websocket"] @@ -52,7 +55,6 @@ Use ``bcrypt``, please install it: npm install --save bcrypt - ##Docker ``Require``: Docker @@ -63,8 +65,8 @@ Use ``bcrypt``, please install it: ``必装``: -1. MongoDB -2. Sqlite 或者 MySQL +1. MongoDB -> NoSQL: 数据存储 +2. Sqlite || MySQL || PostgreSQL || MariaDB || MSSQL -> SQL: 存储用户信息 然后: @@ -87,7 +89,11 @@ Use ``bcrypt``, please install it: npm install -g sequelize-cli sequelize db:migrate -5.运行 +5.Start Cron + + npm jobs/cron.js + +6.运行 npm start @@ -96,7 +102,7 @@ Use ``bcrypt``, please install it: ``require``: Install 1. ``MongoDB`` -2. ``Sqlite`` or ``MySQL`` +2. Sqlite || MySQL || PostgreSQL || MariaDB || MSSQL -> SQL: save user info Then. @@ -112,7 +118,12 @@ Or Just Production only: sequelize db:migrate -3.Run + +3.Start Cron + + npm jobs/cron.js + +4.Run npm start diff --git a/config/default.json b/config/default.json index a3d7524..2944eff 100644 --- a/config/default.json +++ b/config/default.json @@ -15,6 +15,6 @@ "coap": 5683, "mqtt": 1883 }, - "logging": false, + "logging": true, "secret": "keyboard cat" } diff --git a/server/index.js b/server/index.js index cd2ce92..03d08aa 100644 --- a/server/index.js +++ b/server/index.js @@ -64,7 +64,6 @@ router.get('/logout', function (req, res) { 'use strict'; if (req.isAuthenticated()) { req.logout(); - //req.session.messages = req.i18n.__("Log out successfully"); req.session.messages = 'Log out successfully'; } res.redirect('/');