merged private server and console to private-cloud

This commit is contained in:
strawmanbobi
2020-01-12 19:15:08 +08:00
parent 15d977ccd6
commit 90f2d17331
176 changed files with 220265 additions and 0 deletions

View File

@@ -0,0 +1,39 @@
/*
* Created by Strawmanbobi
* 2014-08-30
*/
// global constants describes the ability sets of the POEM framework
global.VERSION = "0.0.4";
global.ICODE = "PoEM~ V0.0.4";
// runtime environment
global.ENV = "dev";
// generic server configuration
global.LISTEN_PORT = "8080";
global.SERVER_ADDRESS = "127.0.0.1";
// local environment
global.FILE_TEMP_PATH = "";
// db : MySQL
global.MYSQL_DB_SERVER_ADDRESS = "127.0.0.1";
global.MYSQL_DB_NAME = "default_db";
global.MYSQL_DB_USER = "root";
global.MYSQL_DB_PASSWORD = "root";
// cache : redis
global.REDIS_HOST = "localhost";
global.REDIS_PORT = "6379";
global.REDIS_PASSWORD = "";
// external : python path
global.PYTHON_PATH = "";
// HTTP request
global.EXTERNAL_SERVER_ADDRESS = "127.0.0.1";
global.EXTERNAL_SERVER_PORT = "80";
global.TOKEN_TTL = 60;

View File

@@ -0,0 +1,36 @@
/*
* Created by Strawmanbobi
* 2014-08-30
*/
function Enums() {
this.APP_PRODUCTION_MODE = "production";
this.APP_DEVELOPMENT_MODE = "development";
this.APP_USERDEBUG_MODE = "userdebug";
this.SERVER_MAIN = 0;
this.SCHEDULER_PERIODICAL = 0;
this.SCHEDULER_ONCE = 1;
this.JPUSH_DEVICE_TYPE_IOS = 0;
this.JPUSH_DEVICE_TYPE_ANDROID = 1;
this.JPUSH_DEVICE_TYPE_BOTH = 2;
this.JPUSH_DEST_TYPE_BROADCAST = 0;
this.JPUSH_DEST_TYPE_PEER = 1;
this.JPUSH_DEST_TYPE_GROUP = 2;
this.JPUSH_PUSH_TYPE_MESSAGE = 0;
this.JPUSH_PUSH_TYPE_NOTIFICATION = 1;
this.BC_API_MESSAGE_TYPE_MESSAGE = 0;
this.BC_API_MESSAGE_TYPE_NOTIFICATION = 1;
this.BC_API_PUSH_TYPE_PEER = 0;
this.BC_API_PUSH_TYPE_BROADCAST = 1;
this.ANDROID_STYPE_0 = 1;
}
module.exports = Enums;

View File

@@ -0,0 +1,24 @@
/*
* Created by Strawmanbobi
* 2014-08-30
*/
function ErrorCode() {
this.SUCCESS = 0;
this.FAILED = -1;
this.PYTHON_SCRIPT_SUCCESS = 0;
this.PYTHON_ARGUMENTS_ERROR = -1;
this.PYTHON_SCRIPT_PATH_NOT_SPECIFIED = -2;
this.PYTHON_CALLBACK_NOT_SPECIFIED = -3;
this.WRONG_PUSH_DEVICE = -50;
this.WRONG_PUSH_TYPE = -51;
this.WRONG_PUSH_DESTINATION = -52;
this.SNS_WEIXIN_VALIDATION_SUCCESS = 0;
this.SNS_WEIXIN_VALIDATION_FAILED = 1;
}
module.exports = ErrorCode;