Built motion from commit 3e059bc2.|2.5.32
[motion2.git] / server / config / pm2 / index.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and   *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0xfb9b=['./config','connect','connected','start','then','disconnect','stop','restart','list','describe','delete','dump','saved','pm2','bluebird'];(function(_0x19e35c,_0x29cd1e){var _0x3e1fe8=function(_0x17258b){while(--_0x17258b){_0x19e35c['push'](_0x19e35c['shift']());}};_0x3e1fe8(++_0x29cd1e);}(_0xfb9b,0x1a2));var _0xbfb9=function(_0x19e679,_0x4c6fa3){_0x19e679=_0x19e679-0x0;var _0x5b604d=_0xfb9b[_0x19e679];return _0x5b604d;};'use strict';var pm2=require(_0xbfb9('0x0'));var BPromise=require(_0xbfb9('0x1'));var config=require(_0xbfb9('0x2'));function connect(){return new BPromise(function(_0x161c58,_0x478fc8){return pm2[_0xbfb9('0x3')](function(_0xa582dd){if(_0xa582dd){return _0x478fc8(_0xa582dd);}return _0x161c58(_0xbfb9('0x4'));});});};exports[_0xbfb9('0x5')]=function(_0x3d5612){return connect()[_0xbfb9('0x6')](function(){return new BPromise(function(_0x371c65,_0xb902f4){return pm2[_0xbfb9('0x5')](_0x3d5612,function(_0x38ea4b,_0x3cf385){if(_0x38ea4b){return _0xb902f4(_0x38ea4b);}pm2[_0xbfb9('0x7')]();return _0x371c65(_0x3cf385);});});});};exports['stop']=function(_0x577f7d){return connect()[_0xbfb9('0x6')](function(){return new BPromise(function(_0x244774,_0xe70c29){return pm2[_0xbfb9('0x8')](_0x577f7d,function(_0x2cb292,_0x312d22){if(_0x2cb292){return _0xe70c29(_0x2cb292);}pm2[_0xbfb9('0x7')]();return _0x244774(_0x312d22);});});});};exports[_0xbfb9('0x9')]=function(_0x206479){return connect()['then'](function(){return new BPromise(function(_0xc98c32,_0x40f1c8){return pm2[_0xbfb9('0x9')](_0x206479,function(_0x520be9,_0x1393f1){if(_0x520be9){return _0x40f1c8(_0x520be9);}pm2[_0xbfb9('0x7')]();return _0xc98c32(_0x1393f1);});});});};exports[_0xbfb9('0xa')]=function(){return connect()['then'](function(){return new BPromise(function(_0xde9cdc,_0x30f11f){return pm2['list'](function(_0x48b71d,_0x1af5ec){if(_0x48b71d){return _0x30f11f(_0x48b71d);}pm2[_0xbfb9('0x7')]();return _0xde9cdc(_0x1af5ec);});});});};exports[_0xbfb9('0xb')]=function(_0x168f1d){return connect()[_0xbfb9('0x6')](function(){return new BPromise(function(_0x15f49a,_0x799653){return pm2[_0xbfb9('0xb')](_0x168f1d,function(_0x39222e,_0x227ee9){if(_0x39222e){return _0x799653(_0x39222e);}pm2[_0xbfb9('0x7')]();return _0x15f49a(_0x227ee9);});});});};exports[_0xbfb9('0xc')]=function(_0x3569b2){return connect()['then'](function(){return new BPromise(function(_0x3ff1ce,_0xc9c6d4){return pm2[_0xbfb9('0xc')](_0x3569b2,function(_0x2c9583,_0x15b7c0){if(_0x2c9583){return _0xc9c6d4(_0x2c9583);}pm2[_0xbfb9('0x7')]();return _0x3ff1ce(_0x15b7c0);});});});};exports[_0xbfb9('0xd')]=function(){return connect()[_0xbfb9('0x6')](function(){return new BPromise(function(_0xc99340,_0x3f5a1e){return pm2['dump'](function(_0x518b7e){if(_0x518b7e){return _0x3f5a1e(_0x518b7e);}return _0xc99340(_0xbfb9('0xe'));});});});};