Skip to content
Alrik Hausdorf edited this page May 5, 2014 · 5 revisions

How to Install/Start

Bash/CMD:

#1. clone Keynode.JS Server:
git clone https://github.com/AKSW/KeyNode.js.git -b server keynode.js.server
cd keynode.js.server

#2. install Required axtensions by running:
npm install

#3.a) copy configuration file (Bash)
cp keynode.js.server_settings.js_sample keynode.js.server_settings.js
#3.b) copy configuration file (Windows)
copy keynode.js.server_settings.js_sample "keynode.js.server_settings.js"

#4. start Server:
node keynode.js.server
#4.a) if you want to bind on Port 80 
      it is posible that you need root-Access
sudo node keynode.js.server

Configuration of the Server

All configurations where made in the keynode.js.server_settings.js

Package-Configuration

If your not using npm, put here the links to the Package.

Default:

this.cryptoPackage     = "crypto";
this.fsPackage         = "fs";
this.httpPackage       = "http";
this.socketIoPackage   = "socket.io";
this.urlPackage        = "url";
this.nodeStatic        = "node-static";
this.NodeMailerPackage = "nodemailer";
this.RequestPackage    = "request";

General-Settings

General settings the Server needs to know.

Default:

this.localInstallation          = true;             //if true, the passwort reset would be send to the Presenter
this.allowAnonymousAuth         = true;             //if true, all Presentations could be controlled by everyone, until a password is set
//this.standardPassword         = 'rootKannAlles';  //global standard password
//this.standardPassword         = (Math.floor(Math.random() * 4257671236709));//random global standard password
this.standardPassword           = false;            //every presentation gets a new random password
this.Server_Port                = 80;               //Port, for the Server to listen on
this.allow_new_presentations    = true;             //accept new presentations

Tag-Configuration

Make the console-log look fancy, each would be printed before a logentry.

Default:

this.preTagInfo       = '\x1B[32m\x1B[1m[Info]\x1B[0m';
this.preTagSettings   = '\x1B[32m\x1B[1m[Settings]\x1B[0m';
this.preTagServerData = '\x1B[32m\x1B[1m[Server_data]\x1B[0m';
this.preTagServer     = '\x1B[32m\x1B[1m[Server]\x1B[0m';
this.preTagPres       = '\x1B[32m\x1B[1m[Presentation]\x1B[0m';

Web-Server-Settings

Configurate where the public folder and the presentations are located.

Default:

this.webRoot              = "public";        //browsable Webfolder
this.presentationFolders  = "presentations"; //Webfolder for Local Presentations (webRoot+"/"+presentationFolders)

Debug-Settings

Configurate if we want to know more what the Server is doing.

Default:

this.debug         = false; //General
this.socketIOdebug = false; //just for Socket.IO

Mailer-Settings

For sending an email for resetting the password. More Options found @ nodemailer

Default:

this.useMail     = false;
this.mailProto   = "SMTP";
this.smtp_options = {
host: "domain.de",
secureConnection: true,
port: 465,
auth: {
	user: "user@Domain.de",
	pass: ""
}
};

Clone this wiki locally