Install NVM (Node Version Manager) - Simple bash script to manage multiple active node.js versions
$ curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.34.0/install.sh | bash
// or
$ wget -qO- https://raw.githubusercontent.com/creationix/nvm/v0.34.0/install.sh | bash
Install latest version :
$ nvm install node # "node" is an alias for the latest version
$ nvm ls
-> v10.15.1
default -> v10.15.1
node -> stable (-> v10.15.1) (default)
stable -> 10.15 (-> v10.15.1) (default)
iojs -> N/A (default)
lts/* -> lts/dubnium (-> v10.15.1)
lts/argon -> v4.9.1 (-> N/A)
lts/boron -> v6.16.0 (-> N/A)
lts/carbon -> v8.15.0 (-> N/A)
lts/dubnium -> v10.15.1
$ npm -g install nodefony
// or with yarn
$ yarn global add nodefony
⸨░░░░░░░░░░░░░░░░░░⸩ ⠧ rollbackFailedOptional: verb npm-session 603461d99e2f3020
...
...
$ nodefony
_ _ ___ ____ _____ _____ ___ _ _ __ __
| \ | | / _ \ | _ \ | ____| | ___| / _ \ | \ | | \ \ / /
| \| | | | | | | | | | | _| | |_ | | | | | \| | \ V /
| |\ | | |_| | | |_| | | |___ | _| | |_| | | |\ | | |
|_| \_| \___/ |____/ |_____| |_| \___/ |_| \_| |_|
Version : 6.0.0-beta.2 Platform : darwin Process : nodefony Pid : 94840
Thu Mar 05 2020 14:37:09 INFO nodefony : WELCOME NODEFONY CLI 6.0.0-beta.2
? Nodefony CLI : (Use arrow keys)
❯ Create Nodefony Web Project
Create Micro Service Project
PM2 Tools
--------
Help
Quit
$ nodefony
_ _ ___ ____ _____ _____ ___ _ _ __ __
| \ | | / _ \ | _ \ | ____| | ___| / _ \ | \ | | \ \ / /
| \| | | | | | | | | | | _| | |_ | | | | | \| | \ V /
| |\ | | |_| | | |_| | | |___ | _| | |_| | | |\ | | |
|_| \_| \___/ |____/ |_____| |_| \___/ |_| \_| |_|
Version : 4.3.1 Platform : darwin Process : nodefony PID : 3520
Tue Mar 26 2019 11:40:45 INFO nodefony : WELCOME NODEFONY CLI 4.3.1
? Nodefony CLI : (Use arrow keys)
❯ Create Nodefony Project
PM2 Tools
--------
Help
Quit
Tue Mar 26 2019 11:45:02 INFO nodefony : WELCOME NODEFONY CLI 4.3.1
? Nodefony CLI : Create Nodefony Project
? Enter Nodefony Project Name nodefony-starter
? Enter short description description nodefony-starter
? Project Path /Users/cci/repository
? Please Enter Author Full Name admin
? Please Enter Email Author admin@nodefony.com
? Enter Server Domain : 0.0.0.0
? Enter server Domain http Port : 5151
? Enter Server Secure Domain https Port : 5152
? Choose default ORM (Mapping Objet Relationnel) : sequelize
? Choose a default Package Manager : npm
? Do You Want Generate Bundle? No
Tue Mar 26 2019 11:45:13 WARNING BUILDER : /Users/cci/repository/nodefony-starter Already exist
? Do You Want Remove : /Users/cci/repository/nodefony-starter? Yes
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :nodefony-starter
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :app
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :appKernel.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :package.json
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :doc
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :index.html.twig
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :README.md
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :services
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :Resources
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :views
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :translations
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :scss
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :databases
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :public
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :manifest.json
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :favicon.ico
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :robots.txt
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :css
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :images
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :config
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :webpack
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :webpack.config.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :config.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :routing.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :services.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :security.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :controller
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :appController.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :loginController.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :usersController.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :package.json
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :.gitignore
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :.jshintrc
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :.jshintignore
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :.editorconfig
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :web
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :tmp
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :config
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :certificates
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :openssl
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :ca
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :openssl.cnf
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :ca_intermediate
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :openssl.cnf
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :config.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :pm2.config.js
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :bin
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create File :generateCertificates.sh
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :src
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :bundles
Tue Mar 26 2019 11:45:28 INFO BUILDER : Create Directory :doc
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :index.html.twig
Tue Mar 26 2019 11:45:28 INFO BUILDER : Copy :README.md
Tue Mar 26 2019 11:45:28 INFO nodefony : Create Project nodefony-starter complete
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create Framework directories
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/tmp/upload
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/web/js
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/web/css
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/web/images
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/web/fonts
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/web/assets
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/web/assets/js
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/web/assets/css
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/web/assets/images
Tue Mar 26 2019 11:45:28 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/web/assets/fonts
Tue Mar 26 2019 11:45:28 INFO nodefony : Spawn : npm install
...
$ cd nodefony-starter
$ ls -la
drwxr-xr-x 18 cci staff 576 26 mar 11:46 .
drwxr-xr-x 26 cci staff 832 26 mar 11:45 ..
-rw-r--r-- 1 cci staff 331 26 mar 11:45 .editorconfig
drwxr-xr-x 13 cci staff 416 26 mar 11:45 .git
-rw-r--r-- 1 cci staff 326 26 mar 11:45 .gitignore
-rw-r--r-- 1 cci staff 13 26 mar 11:45 .jshintignore
-rw-r--r-- 1 cci staff 1068 26 mar 11:45 .jshintrc
-rw-r--r-- 1 cci staff 21306 26 mar 11:45 README.md
drwxr-xr-x 12 cci staff 384 26 mar 11:47 app
drwxr-xr-x 3 cci staff 96 26 mar 11:45 bin
drwxr-xr-x 6 cci staff 192 26 mar 11:46 config
drwxr-xr-x 3 cci staff 96 26 mar 11:45 doc
drwxr-xr-x 1223 cci staff 39136 26 mar 11:46 node_modules
-rw-r--r-- 1 cci staff 730514 26 mar 11:46 package-lock.json
-rw-r--r-- 1 cci staff 1005 26 mar 11:46 package.json
drwxr-xr-x 3 cci staff 96 26 mar 11:45 src
drwxr-xr-x 4 cci staff 128 26 mar 11:47 tmp
drwxr-xr-x 7 cci staff 224 26 mar 11:45 web
Build Project with Github Starter
$ git clone https://github.com/nodefony/nodefony.git
$ cd nodefony
$ nodefony build
Thu Feb 28 2019 16:21:22 INFO INSTALLER : Create Framework directories
Thu Feb 28 2019 16:21:22 INFO nodefony : Spawn : npm install
Thu Feb 28 2019 16:21:36 INFO nodefony : Command : npm install Finished cwd : /Users/cci/repository/nodefony-starter
Thu Feb 28 2019 16:21:36 INFO nodefony : Install Complete
Thu Feb 28 2019 16:21:36 INFO INSTALLER : Clean certificates in : /Users/cci/repository/nodefony-starter/config/certificates
Thu Feb 28 2019 16:21:36 INFO INSTALLER : Create directory /Users/cci/repository/nodefony-starter/config/certificates
Thu Feb 28 2019 16:21:36 INFO INSTALLER : Generate openssl certificates in : /Users/cci/repository/nodefony-starter/config/certificates
Thu Feb 28 2019 16:21:36 INFO nodefony : Spawn : /Users/cci/repository/nodefony-starter/bin/generateCertificates.sh
###################################
# ROOT CA CERTIFICATS #
###################################
Generating RSA private key, 4096 bit long modulus
...........................................................................................................++
...........................................................................................................
writing RSA key
###################################
# ROOT CERTIFICATS INTERMEDIATE #
###################################
Generating RSA private key, 4096 bit long modulus
.......................++
...................................................................................................++
Using configuration from ./config/openssl/ca/openssl.cnf
Check that the request matches the signature
Signature ok
###########################################################
# SIGN SERVER AND CLIENT CERTIFICATES WITH INTERMEDIATE #
###########################################################
Generating RSA private key, 2048 bit long modulus
...................................................................................+++
...........+++
Signature ok
Certificate is to be certified until Mar 9 15:22:28 2020 GMT (375 days)
Write out database with 1 new entries
Data Base Updated
####################
# COPY #
####################
writing RSA key
####################
# VERIFY #
####################
Certificate:
Data:
Version: 3 (0x2)
Serial Number: 4096 (0x1000)
Signature Algorithm: sha256WithRSAEncryption
Issuer: DC=com, DC=nodefony-starter, C=FR, ST=BDR, L=Marseille, O=nodefony-starter Signing Authority, OU=Development, CN=0.0.0.0
Validity
Not Before: Feb 28 15:22:28 2019 GMT
Not After : Mar 9 15:22:28 2020 GMT
Subject: DC=com, DC=nodefony-starter, C=FR, ST=BDR, L=Marseille, O=nodefony-starter Signing Authority, OU=Development, CN=0.0.0.0
Subject Public Key Info:
Public Key Algorithm: rsaEncryption
Public-Key: (2048 bit)
Modulus:
00:dd:3e:b8:5a:77:90:c1:16:6e:bc:80:cf:f4:25:
eb:70:90:ab:90:6b:99:a1:ef:dc:ed:e0:85:20:79:
57:61:f9:a7:eb:e6:b6:a5:b7:fe:fb:a5:5f:24:f7:
1a:f0:c2:fc:a0:96:c2:d6:3d:99:88:b5:e0:60:e1:
ee:a6:30:62:23:fc:81:af:b1:a6:91:31:1d:b3:02:
5c:4d:16:75:70:3e:68:a8:c1:a4:3d:8d:7e:e1:62:
bb:9b:10:67:f2:c4:fe:7a:79:65:13:99:db:e9:7e:
d2:81:a2:91:fb:a6:0c:29:f2:00:73:36:dc:0f:45:
f1:c4:96:c4:68:f2:11:ff:a6:97:ed:28:5c:c7:1a:
f7:84:5e:63:ae:7c:b0:05:10:03:58:d3:ed:18:3f:
b6:51:d4:40:cf:8c:6c:1b:87:b1:a9:8f:5b:e0:57:
0a:91:5f:f2:08:88:43:1a:94:37:6e:39:a0:a0:4e:
69:dc:3c:de:e5:77:2a:8e:9c:9d:97:70:71:73:0e:
17:6f:bf:20:fb:7c:9f:ed:29:c7:0a:53:e5:62:c0:
1b:0a:51:3d:77:a6:63:d8:d6:c1:ca:62:6d:7d:b9:
e1:49:ce:be:77:ef:a7:50:b3:f3:58:62:e4:92:e8:
67:af:e2:e0:bb:fa:c2:b7:08:d7:39:3b:c9:69:0e:
4a:95
Exponent: 65537 (0x10001)
X509v3 extensions:
X509v3 Basic Constraints:
CA:FALSE
Netscape Cert Type:
SSL Server
Netscape Comment:
OpenSSL Generated Server Certificate
X509v3 Subject Key Identifier:
18:32:25:6D:8B:25:DD:F9:09:D1:47:E4:C7:CE:B0:24:4E:07:C0:4F
X509v3 Authority Key Identifier:
keyid:DE:F1:C3:DA:9B:A1:75:05:76:3E:4C:7F:9B:AB:D5:9B:F4:FA:84:59
DirName:/DC=com/DC=nodefony-starter/C=FR/ST=BDR/L=Marseille/O=nodefony-starter Signing Authority/OU=Development/emailAddress=admin@nodefony.com/CN=0.0.0.0
serial:10:00
X509v3 Key Usage: critical
Digital Signature, Key Encipherment
X509v3 Extended Key Usage:
TLS Web Server Authentication
X509v3 Subject Alternative Name:
IP Address:127.0.0.1, IP Address:0.0.0.0, DNS:localhost, DNS:docker.nodefony-starter.com, DNS:nodefony-starter.com
Signature Algorithm: sha256WithRSAEncryption
92:10:cd:b5:d4:48:b6:d3:d8:e9:30:20:b0:42:37:9f:a2:20:
c7:81:47:c9:96:6e:95:66:08:f0:fe:ee:d5:23:ad:05:e6:56:
a9:00:a5:4f:5c:ce:83:0b:e0:de:b0:c4:a2:71:09:ee:71:ee:
0e:7a:6f:86:27:ec:1a:f4:a4:77:7a:7c:2d:ab:40:63:79:44:
fd:49:65:91:50:ce:bc:49:f1:f8:b1:28:83:9e:a3:36:ab:3f:
ea:c6:b5:7d:40:6a:37:98:da:2e:1c:d0:04:7c:6c:ed:3f:69:
12:94:72:f6:d8:86:24:11:a4:da:ae:cf:45:55:1c:43:06:bc:
11:ed:bb:c8:5d:08:8b:ac:ef:3b:d2:f3:7f:1d:63:a2:9e:0e:
2e:b7:ff:99:38:92:98:3b:8b:d7:27:4b:93:ff:8d:4c:ce:12:
75:60:ca:0f:e3:6c:79:cc:a8:5a:57:38:34:32:b9:71:61:f3:
1c:f8:36:31:e4:7b:4e:70:67:9c:d2:f3:57:2d:77:d4:5b:7e:
96:a4:af:72:48:25:7a:9a:8b:5b:08:30:f4:e3:e1:55:3e:48:
db:ec:8e:47:4d:f6:54:b0:5c:b8:5d:21:e5:db:5c:73:c4:4a:
b9:c3:1a:7e:87:91:e4:3d:32:ad:dd:74:3c:fe:96:e6:71:a3:
f0:29:60:10:2d:cd:cf:3b:61:24:66:fc:ca:1c:56:4f:a3:02:
1a:26:c9:44:c4:10:92:1e:43:82:74:4a:b2:30:1f:ee:32:52:
cb:c1:99:b1:4c:92:49:a7:17:b5:72:3d:5b:ad:58:37:9b:ba:
02:46:93:4e:1e:5e:4d:57:38:df:11:cf:15:34:f9:24:72:60:
ec:3f:40:bb:49:b0:8a:8f:ac:6e:22:c8:e9:87:db:02:ce:06:
9c:01:e5:50:af:9b:90:9c:b5:c5:9c:4d:33:01:ef:9a:cd:51:
33:48:9e:9e:d2:aa:0e:7e:48:26:e5:b1:de:96:2e:06:0b:ba:
18:23:7e:ae:64:55:42:78:c9:cc:9a:d2:c4:8d:86:12:80:7c:
91:de:18:45:aa:19:b4:95:e7:1f:24:8c:a5:82:fb:d8:25:d6:
cc:44:c3:55:d1:e0:a2:a4:3e:17:57:85:e2:3e:a3:79:fd:f4:
fb:40:3c:aa:bb:8d:15:dc:e0:a4:40:a6:5d:92:3e:64:f4:31:
20:c0:23:3f:db:41:13:cf:b7:ae:29:8f:17:28:82:05:74:14:
c5:96:d8:f2:ee:8c:3a:78:15:b3:dc:bf:18:71:51:31:d0:d8:
72:18:a0:91:da:f0:02:b4:61:0a:a1:a4:39:7e:d1:5c:c7:68:
ef:6a:04:24:07:f0:52:66
####################
# HAPROXY #
####################
Thu Feb 28 2019 16:22:28 INFO nodefony : Build Complete
_ __ _ _
_ __ ___ __| | ___ / _| ___ _ __ _ _ ___ | |_ __ _ _ __ | |_ ___ _ __
| '_ \ / _ \ / _` | / _ \ | |_ / _ \ | '_ \ | | | | _____ / __| | __| / _` | | '__| | __| / _ \ | '__|
| | | | | (_) | | (_| | | __/ | _| | (_) | | | | | | |_| | |_____| \__ \ | |_ | (_| | | | | |_ | __/ | |
|_| |_| \___/ \__,_| \___| |_| \___/ |_| |_| \__, | |___/ \__| \__,_| |_| \__| \___| |_|
|___/
Version : 1.0.0 Platform : darwin Process : nodefony-starter PID : 79180
KERNEL CONSOLE Cluster : master Environment : prod Debug :false
Thu Feb 28 2019 16:22:28 INFO KERNEL CONSOLE : Find NPM Bundle Package : http-bundle in : /Users/cci/repository/nodefony-starter/node_modules/@nodefony/http-bundle/httpBundle.js
Thu Feb 28 2019 16:22:28 INFO KERNEL CONSOLE : Find NPM Bundle Package : framework-bundle in : /Users/cci/repository/nodefony-starter/node_modules/@nodefony/framework-bundle/frameworkBundle.js
Thu Feb 28 2019 16:22:28 INFO KERNEL CONSOLE : Find NPM Bundle Package : security-bundle in : /Users/cci/repository/nodefony-starter/node_modules/@nodefony/security-bundle/securityBundle.js
Thu Feb 28 2019 16:22:28 INFO KERNEL CONSOLE : Find NPM Bundle Package : sequelize-bundle in : /Users/cci/repository/nodefony-starter/node_modules/@nodefony/sequelize-bundle/sequelizeBundle.js
Thu Feb 28 2019 16:22:28 INFO KERNEL CONSOLE : Find NPM Bundle Package : realtime-bundle in : /Users/cci/repository/nodefony-starter/node_modules/@nodefony/realtime-bundle/realtimeBundle.js
Thu Feb 28 2019 16:22:28 INFO KERNEL CONSOLE : Find NPM Bundle Package : monitoring-bundle in : /Users/cci/repository/nodefony-starter/node_modules/@nodefony/monitoring-bundle/monitoringBundle.js
Thu Feb 28 2019 16:22:28 INFO KERNEL CONSOLE : Find NPM Bundle Package : documentation-bundle in : /Users/cci/repository/nodefony-starter/node_modules/@nodefony/documentation-bundle/documentationBundle.js
Thu Feb 28 2019 16:22:28 INFO KERNEL CONSOLE : Find NPM Bundle Package : unittests-bundle in : /Users/cci/repository/nodefony-starter/node_modules/@nodefony/unittests-bundle/unittestsBundle.js
Thu Feb 28 2019 16:22:28 INFO nodefony : Spawn : npm install
audited 11912 packages in 5.052s
found 0 vulnerabilities
Thu Feb 28 2019 16:22:34 INFO nodefony : Command : npm install Finished cwd : /Users/cci/repository/nodefony-starter/app
_ __
_ __ ___ __| | ___ / _| ___ _ __ _ _
| '_ \ / _ \ / _` | / _ \ | |_ / _ \ | '_ \ | | | |
| | | | | (_) | | (_| | | __/ | _| | (_) | | | | | | |_| |
|_| |_| \___/ \__,_| \___| |_| \___/ |_| |_| \__, |
|___/
Thu Feb 28 2019 16:22:36 INFO COMMAND : nodefony:build /Users/cci/repository/nodefony-starter
Thu Feb 28 2019 16:22:36 INFO COMMAND nodefony : BUILD NODEFONY FRAMEWORK
Thu Feb 28 2019 16:22:36 INFO COMMAND nodefony : INITIALIZE ORM
Thu Feb 28 2019 16:22:36 INFO COMMAND nodefony : INITIALIZE SEQUELIZE
Thu Feb 28 2019 16:22:36 INFO COMMAND sequelize TASK sync : DATABASE : sqlite CONNECTION : nodefony
Thu Feb 28 2019 16:22:36 INFO COMMAND sequelize TASK sync : DATABASE SYNC : nodefony
Thu Feb 28 2019 16:22:36 INFO nodefony : Executing (default): CREATE TABLE IF NOT EXISTS `requests` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `remoteAddress` VARCHAR(255), `userAgent` VARCHAR(255), `url` TEXT, `route` VARCHAR(255), `method` VARCHAR(255), `state` VARCHAR(255), `protocole` VARCHAR(255), `username` VARCHAR(255), `data` TEXT, `createdAt` DATETIME NOT NULL, `updatedAt` DATETIME NOT NULL);
Thu Feb 28 2019 16:22:36 INFO nodefony : Executing (default): PRAGMA INDEX_LIST(`requests`)
Thu Feb 28 2019 16:22:36 INFO nodefony : Executing (default): CREATE TABLE IF NOT EXISTS `sessions` (`session_id` VARCHAR(126) NOT NULL, `context` VARCHAR(126) DEFAULT 'default' NOT NULL, `username` VARCHAR(126) DEFAULT '', `Attributes` JSON, `flashBag` JSON, `metaBag` JSON, `createdAt` DATETIME, `updatedAt` DATETIME, PRIMARY KEY (`session_id`, `context`));
Thu Feb 28 2019 16:22:36 INFO nodefony : Executing (default): PRAGMA INDEX_LIST(`sessions`)
Thu Feb 28 2019 16:22:36 INFO nodefony : Executing (default): PRAGMA INDEX_INFO(`sqlite_autoindex_sessions_1`)
Thu Feb 28 2019 16:22:36 INFO nodefony : Executing (default): CREATE TABLE IF NOT EXISTS `users` (`username` VARCHAR(126) NOT NULL UNIQUE NOT NULL, `password` VARCHAR(256), `enabled` TINYINT(1) DEFAULT 1, `userNonExpired` TINYINT(1) DEFAULT 1, `credentialsNonExpired` TINYINT(1) DEFAULT 1, `accountNonLocked` TINYINT(1) DEFAULT 1, `email` VARCHAR(255) NOT NULL UNIQUE NOT NULL, `name` VARCHAR(255), `surname` VARCHAR(255), `lang` VARCHAR(255) DEFAULT 'en_en', `roles` JSON DEFAULT '[]', `gender` VARCHAR(255) DEFAULT 'none', `url` VARCHAR(255), `image` VARCHAR(255), `createdAt` DATETIME NOT NULL, `updatedAt` DATETIME NOT NULL, PRIMARY KEY (`username`, `email`));
Thu Feb 28 2019 16:22:36 INFO nodefony : Executing (default): PRAGMA INDEX_LIST(`users`)
Thu Feb 28 2019 16:22:36 INFO nodefony : Executing (default): PRAGMA INDEX_INFO(`sqlite_autoindex_users_1`)
Thu Feb 28 2019 16:22:36 INFO COMMAND sequelize TASK sync : DATABASE :/app/Resources/databases/nodefony.db CONNECTION : nodefony CREATE ALL TABLES
Thu Feb 28 2019 16:22:36 INFO COMMAND nodefony : Generate Fixtures
Thu Feb 28 2019 16:22:36 INFO COMMAND sequelize TASK fixtures : LOAD FIXTURES BUNDLE : sequelize
Thu Feb 28 2019 16:22:36 INFO COMMAND sequelize TASK fixtures : LOAD FIXTURE ENTITY : user CONNECTIONS : nodefony
Thu Feb 28 2019 16:22:36 INFO sequelize : Database synchronised
Thu Feb 28 2019 16:22:36 INFO sequelize : ALREADY EXIST USER : anonymous
Thu Feb 28 2019 16:22:36 INFO sequelize : ALREADY EXIST USER : admin
Thu Feb 28 2019 16:22:36 INFO sequelize : ALREADY EXIST USER : 1000
Thu Feb 28 2019 16:22:36 INFO sequelize : ALREADY EXIST USER : 2000
Thu Feb 28 2019 16:22:36 INFO sequelize : ALREADY EXIST USER : 3000
Thu Feb 28 2019 16:22:36 INFO COMMAND sequelize TASK fixtures : LOAD FIXTURE ENTITY : SUCCESS
Thu Feb 28 2019 16:22:36 INFO COMMAND nodefony : ROUTING LIST
┌────┬───────────────────────────────────────┬─────────────────────────────────────────────┬──────────────────────┬────────────┬─────────────────────┐
│ NB │ ROUTE │ PATH │ BUNDLE │ CONTROLLER │ ACTION │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 1 │ realSecure │ /secure/realtime │ realtime │ default │ index │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 2 │ real │ /realtime │ realtime │ default │ index │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 3 │ monitoring-index │ /nodefony │ monitoring │ default │ index │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 4 │ monitoring-module │ /nodefony/{module} │ monitoring │ default │ index │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 5 │ monitoring-realtime │ /nodefony/monitoring/realtime │ monitoring │ default │ realTime │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 6 │ monitoring-routes │ /nodefony/api/routes │ monitoring │ api │ routes │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 7 │ monitoring-route │ /nodefony/api/route/{name} │ monitoring │ api │ routes │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 8 │ monitoring-services │ /nodefony/api/services │ monitoring │ api │ services │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 9 │ monitoring-service │ /nodefony/api/service/{name} │ monitoring │ api │ services │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 10 │ monitoring-syslog │ /nodefony/api/syslog │ monitoring │ api │ syslog │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 11 │ monitoring-requests │ /nodefony/api/requests │ monitoring │ api │ requests │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 12 │ monitoring-request │ /nodefony/api/request/{uid} │ monitoring │ api │ request │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 13 │ monitoring-config │ /nodefony/api/config │ monitoring │ api │ config │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 14 │ monitoring-bundle │ /nodefony/api/config/{bundleName} │ monitoring │ api │ bundle │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 15 │ monitoring-real │ /nodefony/api/realtime/{name} │ monitoring │ api │ realtime │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 16 │ monitoring-users │ /nodefony/api/users │ monitoring │ api │ users │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 17 │ monitoring-sessions │ /nodefony/api/sessions │ monitoring │ api │ sessions │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 18 │ monitoring-pm2 │ /nodefony/api/pm2/{action} │ monitoring │ api │ pm2 │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 19 │ monitoring-security │ /nodefony/api/security │ monitoring │ api │ security │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 20 │ monitoring-test-load │ /nodefony/test/load │ monitoring │ default │ testLoad │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 21 │ documentation-search │ /documentation/search │ documentation │ default │ search │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 22 │ documentation │ /documentation/{version}/{bundle} │ documentation │ default │ version │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 23 │ documentation-version │ /documentation/{version}/{bundle} │ documentation │ default │ version │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 24 │ documentation-section │ /documentation/{version}/{bundle}/{section} │ documentation │ default │ version │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 25 │ documentation-demo-html │ /doc/demo/html/{name} │ documentation │ demo │ html │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 26 │ documentation-demo-render │ /doc/demo/render/{name} │ documentation │ demo │ render │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 27 │ home │ / │ app │ app │ index │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 28 │ documentation-git-versions │ /api/git/versions/{project} │ documentation-bundle │ git │ getVersions │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 29 │ documentation-git-getStatus │ /api/git/getStatus/{project} │ documentation-bundle │ git │ getStatus │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 30 │ documentation-git-getBranch │ /api/git/getCurrentBranch/{project} │ documentation-bundle │ git │ getCurrentBranch │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 31 │ documentation-git-getMostRecentCommit │ /api/git/getMostRecentCommit/{project} │ documentation-bundle │ git │ getMostRecentCommit │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 32 │ lang │ /lang │ app │ app │ lang │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 33 │ login │ /login/{type} │ app │ login │ login │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 34 │ login-check │ /login/check │ app │ login │ loginCheck │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 35 │ logout │ /logout │ app │ login │ logout │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 36 │ doc-lang │ /document/lang │ documentation-bundle │ default │ lang │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 37 │ nodefony-user-create │ /users/create │ app │ users │ create │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 38 │ nodefony-user-update │ /users/update/{username} │ app │ users │ update │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 39 │ nodefony-user-delete │ /users/delete/{username} │ app │ users │ delete │
├────┼───────────────────────────────────────┼─────────────────────────────────────────────┼──────────────────────┼────────────┼─────────────────────┤
│ 40 │ nodefony-user │ /users/{username} │ app │ users │ user │
└────┴───────────────────────────────────────┴─────────────────────────────────────────────┴──────────────────────┴────────────┴─────────────────────┘
Thu Feb 28 2019 16:22:36 INFO COMMAND nodefony : ROUTING LIST
Thu Feb 28 2019 16:22:36 INFO COMMAND router TASK display : URI TO CHECK : /
┌────┬───────┬──────┬────────┬────────────┬────────┬─────────────┐
│ NB │ ROUTE │ PATH │ BUNDLE │ CONTROLLER │ ACTION │ FIRST MATCH │
├────┼───────┼──────┼────────┼────────────┼────────┼─────────────┤
│ 1 │ home │ / │ app │ app │ index │ * │
└────┴───────┴──────┴────────┴────────────┴────────┴─────────────┘
Thu Feb 28 2019 16:22:36 INFO nodefony : NODEFONY PACKAGES :/Users/cci/repository/nodefony-starter/package.json
Thu Feb 28 2019 16:22:36 INFO nodefony : NODEFONY PACKAGES :/Users/cci/repository/nodefony-starter/app/package.json
┌──────────────────────────────┬──────────┬────────────────────────────────────────────────────────────────────────────────────────────────────┬────────────────────┐
│ NAME │ VERSION │ DESCRIPTION │ BUNDLES │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ @babel/core │ 7.3.4 │ Babel compiler core. │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ @babel/preset-env │ 7.3.4 │ A Babel preset for each environment. │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ autoprefixer │ 9.4.9 │ Parse CSS and add vendor prefixes to CSS rules using values from the Can I Use website │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ babel-loader │ 8.0.5 │ babel module loader for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ bootstrap │ 4.3.1 │ The most popular front-end framework for developing responsive, mobile first projects on the web. │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ clean-webpack-plugin │ 1.0.1 │ A webpack plugin to remove your build folder(s) before building │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ css-hot-loader │ 1.4.3 │ css hot reload work with extract-text-webpack-plugin │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ css-loader │ 2.1.0 │ css loader module for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ expose-loader │ 0.7.5 │ expose loader module for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ file-loader │ 3.0.1 │ A file loader module for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ font-awesome │ 4.7.0 │ The iconic font and CSS framework │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ image-webpack-loader │ 4.6.0 │ Image loader module for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ imports-loader │ 0.8.0 │ imports loader module for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ jquery │ 3.3.1 │ JavaScript library for DOM operations │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ mini-css-extract-plugin │ 0.5.0 │ extracts CSS into separate files │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ node-sass │ 4.11.0 │ Wrapper around libsass │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ optimize-css-assets-webpack… │ 5.0.1 │ A Webpack plugin to optimize \ minimize CSS assets. │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ popper.js │ 1.14.7 │ A kickass library to manage your poppers │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ postcss-loader │ 3.0.0 │ PostCSS loader for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ precss │ 4.0.0 │ Use Sass-like markup and staged CSS features in CSS │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ raw-loader │ 1.0.0 │ A loader for webpack that allows importing files as a String │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ resolve-url-loader │ 3.0.1 │ Webpack loader that resolves relative paths in url() statements based on the original source file │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ sass-loader │ 7.1.0 │ Sass loader for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ style-loader │ 0.23.1 │ style loader module for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ terser-webpack-plugin │ 1.2.3 │ Terser plugin for webpack │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ webpack │ 4.29.6 │ Packs CommonJs/AMD modules for the browser. Allows to split your codebase into multiple bundles, … │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ webpack-merge │ 4.2.1 │ Variant of merge that's useful for webpack configuration │ app │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ mongoose │ 5.4.16 │ Mongoose MongoDB ODM │ nodefony-starter │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ nodefony │ 4.2.0-b… │ Nodefony Framework Core │ nodefony-starter │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ sequelize │ 5.0.0-b… │ Multi dialect ORM for Node.JS │ nodefony-starter │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ webpack │ 4.29.6 │ Packs CommonJs/AMD modules for the browser. Allows to split your codebase into multiple bundles, … │ nodefony-starter │
├──────────────────────────────┼──────────┼────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┤
│ webpack-dev-server │ 3.2.1 │ Serves a webpack app. Updates the browser on changes. │ nodefony-starter │
└──────────────────────────────┴──────────┴────────────────────────────────────────────────────────────────────────────────────────────────────┴────────────────────┘
Thu Feb 28 2019 16:22:42 INFO KERNEL CONSOLE : NODEFONY Kernel Life Cycle Terminate CODE : 0
YOU CAN USE CLI INTERACTIVE MODE TO BUILD PROJECT (nodefony without args)
$ nodefony #$ nodefony create nodefony-starter /Users/documents
_ _ ___ ____ _____ _____ ___ _ _ __ __
| \ | | / _ \ | _ \ | ____| | ___| / _ \ | \ | | \ \ / /
| \| | | | | | | | | | | _| | |_ | | | | | \| | \ V /
| |\ | | |_| | | |_| | | |___ | _| | |_| | | |\ | | |
|_| \_| \___/ |____/ |_____| |_| \___/ |_| \_| |_|
Version : 4.2.0-beta.2 Platform : darwin Process : nodefony PID : 75632
Thu Feb 28 2019 11:33:00 INFO nodefony : WELCOME NODEFONY CLI 4.2.0-beta.2
? Nodefony CLI : (Use arrow keys)
❯ Create Nodefony Project
PM2 Tools
--------
Help
Quit
? Nodefony CLI : Create Nodefony Project
? Enter Nodefony Project Name : nodefony-starter
? Enter short description description : nodefony-starter
? Project : Path /Users/documents
? Please Enter Author Full Name : admin
? Please Enter Email Author : admin@nodefony.com
? Enter Server Domain : 0.0.0.0
? Enter server Domain http Port : 5151
? Enter Server Secure Domain https Port : 5152
? Choose default ORM (Mapping Objet Relationnel) : sequelize
? Choose a default Package Manager : npm
? Do You Want Generate Bundle? No
...
Serving a Nodefony project via an development server Starting Development Servers
$ nodefony dev
// TO STOP
$ <ctrl-c>
Starting Development Servers in Debug Mode (-d)
$ nodefony -d dev
// TO STOP
$ <ctrl-c>
Starting Servers Production (PM2)
$ nodefony start # or nodefony prod
┌──────────────────┬────┬──────────────┬───────┬────────┬─────────┬───────────────────┬─────┬────────┬──────┬──────────┐
│ App name │ id │ mode │ pid │ status │ restart │ uptime │ cpu │ memory │ user │ watching │
├──────────────────┼────┼──────────────┼───────┼────────┼─────────┼───────────────────┼─────┼────────┼──────┼──────────┤
│ nodefony-starter │ 0 │ cluster_mode │ 79361 │ online │ - │ a few seconds ago │ 71% │ 56 MB │ cci │ - │
├──────────────────┼────┼──────────────┼───────┼────────┼─────────┼───────────────────┼─────┼────────┼──────┼──────────┤
│ nodefony-starter │ 1 │ cluster_mode │ 79362 │ online │ - │ a few seconds ago │ 65% │ 54 MB │ cci │ - │
├──────────────────┼────┼──────────────┼───────┼────────┼─────────┼───────────────────┼─────┼────────┼──────┼──────────┤
│ nodefony-starter │ 2 │ cluster_mode │ 79365 │ online │ - │ a few seconds ago │ 55% │ 51 MB │ cci │ - │
├──────────────────┼────┼──────────────┼───────┼────────┼─────────┼───────────────────┼─────┼────────┼──────┼──────────┤
│ nodefony-starter │ 3 │ cluster_mode │ 79372 │ online │ - │ a few seconds ago │ 42% │ 45 MB │ cci │ - │
├──────────────────┼────┼──────────────┼───────┼────────┼─────────┼───────────────────┼─────┼────────┼──────┼──────────┤
│ nodefony-starter │ 4 │ cluster_mode │ 79377 │ online │ - │ a few seconds ago │ 36% │ 39 MB │ cci │ - │
├──────────────────┼────┼──────────────┼───────┼────────┼─────────┼───────────────────┼─────┼────────┼──────┼──────────┤
│ nodefony-starter │ 5 │ cluster_mode │ 79382 │ online │ - │ a few seconds ago │ 25% │ 33 MB │ cci │ - │
├──────────────────┼────┼──────────────┼───────┼────────┼─────────┼───────────────────┼─────┼────────┼──────┼──────────┤
│ nodefony-starter │ 6 │ cluster_mode │ 79387 │ online │ - │ a few seconds ago │ 0% │ 27 MB │ cci │ - │
├──────────────────┼────┼──────────────┼───────┼────────┼─────────┼───────────────────┼─────┼────────┼──────┼──────────┤
│ nodefony-starter │ 7 │ cluster_mode │ 79392 │ online │ - │ a few seconds ago │ 0% │ 21 MB │ cci │ - │
└──────────────────┴────┴──────────────┴───────┴────────┴─────────┴───────────────────┴─────┴────────┴──────┴──────────┘
To see all logs use the command nodefony logs
Or use PM2 pm2 --lines 1000 logs
// To stop
$ nodefony stop
// To kill pm2 Manager
$ nodefony kill
Usefull to check and use clusters
$ nodefony preprod
KERNEL SERVER Cluster : worker Environment : prod Debug :false
_ __ _ _
_ __ ___ __| | ___ / _| ___ _ __ _ _ ___ | |_ __ _ _ __ | |_ ___ _ __
| '_ \ / _ \ / _` | / _ \ | |_ / _ \ | '_ \ | | | | _____ / __| | __| / _` | | '__| | __| / _ \ | '__|
| | | | | (_) | | (_| | | __/ | _| | (_) | | | | | | |_| | |_____| \__ \ | |_ | (_| | | | | |_ | __/ | |
|_| |_| \___/ \__,_| \___| |_| \___/ |_| |_| \__, | |___/ \__| \__,_| |_| \__| \___| |_|
|___/
Version : 1.0.0 Platform : darwin Process : nodefony-starter PID : 86633
KERNEL SERVER Cluster : worker Environment : prod Debug :false
...
$ nodefony # or npm start
_ _ ___ ____ _____ _____ ___ _ _ __ __
| \ | | / _ \ | _ \ | ____| | ___| / _ \ | \ | | \ \ / /
| \| | | | | | | | | | | _| | |_ | | | | | \| | \ V /
| |\ | | |_| | | |_| | | |___ | _| | |_| | | |\ | | |
|_| \_| \___/ |____/ |_____| |_| \___/ |_| \_| |_|
Version : 4.2.0-beta.2 Platform : darwin Process : nodefony PID : 77661
Thu Feb 28 2019 15:29:39 INFO nodefony : WELCOME PROJECT : nodefony-starter 1.0.0
? Nodefony CLI : (Use arrow keys)
❯ Start Servers Development
Start Servers Pre-Production
Start Servers Production
Install Project
Rebuild Project
Generater
Tools
PM2 Tools
Run Test
--------
Help
Quit
# RENDER STATICS CDN
server {
listen 80;
listen 443 ssl;
server_name static.nodefony.com;
ssl_certificate /path_to_nodefony/config/certificates/nodefony.fr/fullchain.pem;
ssl_certificate_key /path_to_nodefony/config/certificates/nodefony.fr/privkey.pem;
ssl_trusted_certificate /path_to_nodefony/config/certificates/nodefony.fr/fullchain.pem;
location ~* \.(gif|jpg|jpeg|png|wmv|avi|mpg|mpeg|mp4|webm|htm|html|js|css|mp3|swf|ico|flv|woff.?|ttf)$ {
access_log off;
root /path_to_nodefony/web;
expires 7d;
add_header access-control-allow-origin *;
}
}
server {
listen 80;
server_name nodefony.com;
set $via "1.0 nodefony nginx front";
if ($http_via) {
set $via "$http_via, 1.0 nodefony nginx front";
}
location / {
root /path_to_nodefony/web ;
proxy_pass http://nodefony.com:5151;
proxy_http_version 1.1;
proxy_pass_header Server;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Port $server_port;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Server $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Via $via;
proxy_cache_bypass $http_upgrade;
}
location ~ \.(js|css|png|ico|jpg|jpeg|gif|ttf|font|map|woff.?|twig|txt|html|xml|json|mp3|wmv|avi|mpg|mpeg|mp4|webm|swf|flv)$ {
access_log off;
root /path_to_nodefony/web;
expires 7d;
}
}
server {
listen 443 ssl;
server_name nodefony.com;
ssl_certificate /path_to_nodefony/config/certificates/nodefony.fr/fullchain.pem;
ssl_certificate_key /path_to_nodefony/config/certificates/nodefony.fr/privkey.pem;
ssl_trusted_certificate /path_to_nodefony/config/certificates/nodefony.fr/fullchain.pem;
set $via "1.0 nodefony nginx front";
if ($http_via) {
set $via "$http_via, 1.0 nodefony nginx front";
}
location / {
root /path_to_nodefony/web ;
proxy_pass https://nodefony.com:5152;
proxy_http_version 1.1;
proxy_pass_header Server;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Port $server_port ;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Server $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Via $via;
proxy_cache_bypass $http_upgrade;
}
location ~ \.(js|css|png|ico|jpg|jpeg|gif|ttf|font|map|woff.?|twig|txt|html|xml|json|mp3|wmv|avi|mpg|mpeg|mp4|webm|swf|flv)$ {
root /path_to_nodefony/web;
expires 7d;
access_log off;
}
}
Microservices are a software development technique a variant of the service-oriented architecture (SOA) structural style that arranges an application as a collection of loosely coupled services. In a microservices architecture, services are fine-grained and the protocols are lightweight.
$ nodefony
Thu Mar 05 2020 14:37:09 INFO nodefony : WELCOME NODEFONY CLI 6.0.0-beta.2
? Nodefony CLI :
Create Nodefony Web Project
❯ Create Micro Service Project
PM2 Tools
--------
Help
Quit
$ la -l
total 3432
-rw-r--r-- 1 cci staff 331 5 mar 11:28 .editorconfig
-rw-r--r-- 1 cci staff 636 5 mar 11:28 .env-cmdrc.js
drwxr-xr-x 12 cci staff 384 5 mar 11:35 .git
-rw-r--r-- 1 cci staff 450 5 mar 11:28 .gitignore
-rw-r--r-- 1 cci staff 643 5 mar 11:28 .jshintrc
-rw-r--r-- 1 cci staff 2430 5 mar 11:28 README.md
drwxr-xr-x 5 cci staff 160 5 mar 11:28 bin
drwxr-xr-x 5 cci staff 160 5 mar 11:28 config
drwxr-xr-x 2 cci staff 64 5 mar 11:28 dist
drwxr-xr-x 1562 cci staff 49984 5 mar 11:46 node_modules
-rw-r--r-- 1 cci staff 1006407 5 mar 11:31 package-lock.json
-rw-r--r-- 1 cci staff 1934 5 mar 11:31 package.json
drwxr-xr-x 6 cci staff 192 5 mar 11:28 src
drwxr-xr-x 3 cci staff 96 5 mar 11:28 tests
drwxr-xr-x 3 cci staff 96 5 mar 11:32 tmp
$ npm start
$ node ./bin/cli
_ __ _
_ __ ___ __| | ___ / _| ___ _ __ _ _ ___ ___ _ __ __ __ (_) ___ ___
| '_ \ / _ \ / _` | / _ \ | |_ / _ \ | '_ \ | | | | _____ / __| / _ \ | '__| \ \ / / | | / __| / _ \
| | | | | (_) | | (_| | | __/ | _| | (_) | | | | | | |_| | |_____| \__ \ | __/ | | \ V / | | | (__ | __/
|_| |_| \___/ \__,_| \___| |_| \___/ |_| |_| \__, | |___/ \___| |_| \_/ |_| \___| \___|
|___/
Version : 1.0.0 Platform : darwin Process : nodefony-service Pid : 214
? CLI (Use arrow keys)
❯ Development
Production
Pm2
Build
Test
Quit
$ npm run dev
> nodefony-service@1.0.0 dev /Users/cci/repository/test/nodefony-service
> env-cmd -e development pm2 start config/pm2.config.js --env development --no-daemon
pm2 launched in no-daemon mode (you can add DEBUG="*" env variable to get more messages)
2020-03-05T17:12:18: PM2 log: Launching in no daemon mode
2020-03-05T17:12:18: PM2 log: [PM2][WARN] Applications nodefony-service not running, starting...
2020-03-05T17:12:18: PM2 log: [PM2][WARN] Environment [development] is not defined in process file
2020-03-05T17:12:18: PM2 log: [Watch] Start watching nodefony-service
2020-03-05T17:12:18: PM2 log: App [nodefony-service:0] starting in -fork mode-
2020-03-05T17:12:18: PM2 log: App [nodefony-service:0] online
2020-03-05T17:12:18: PM2 log: [PM2] App [nodefony-service] launched (1 instances)
2020-03-05T17:12:18: PM2 log:
┌─────┬─────────────────────┬─────────────┬─────────┬─────────┬──────────┬────────┬──────┬───────────┬──────────┬──────────┬──────────┬──────────┐
│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │
├─────┼─────────────────────┼─────────────┼─────────┼─────────┼──────────┼────────┼──────┼───────────┼──────────┼──────────┼──────────┼──────────┤
│ 0 │ nodefony-service │ default │ 1.0.0 │ fork │ 329 │ 0s │ 0 │ online │ 0% │ 14.3mb │ cci │ enabled │
└─────┴─────────────────────┴─────────────┴─────────┴─────────┴──────────┴────────┴──────┴───────────┴──────────┴──────────┴──────────┴──────────┘
2020-03-05T17:12:18: PM2 log: [PM2][WARN] Current process list running is not in sync with saved list. cci differs. Type 'pm2 save' to synchronize.
2020-03-05T17:12:18: PM2 log: [--no-daemon] Continue to stream logs
2020-03-05T17:12:18: PM2 log: [--no-daemon] Exit on target PM2 exit pid=328
$ npm run prod
> nodefony-service@1.0.0 prod /Users/cci/repository/test/nodefony-service
> env-cmd -e production pm2 start config/pm2.config.js --env production
[PM2] Spawning PM2 daemon with pm2_home=/Users/cci/.pm2
[PM2] PM2 Successfully daemonized
[PM2][WARN] Applications nodefony-service not running, starting...
[PM2] App [nodefony-service] launched (8 instances)
┌─────┬─────────────────────┬─────────────┬─────────┬─────────┬──────────┬────────┬──────┬───────────┬──────────┬──────────┬──────────┬──────────┐
│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │
├─────┼─────────────────────┼─────────────┼─────────┼─────────┼──────────┼────────┼──────┼───────────┼──────────┼──────────┼──────────┼──────────┤
│ 0 │ nodefony-service │ default │ 1.0.0 │ cluster │ 368 │ 0s │ 0 │ online │ 0% │ 42.0mb │ cci │ disabled │
│ 1 │ nodefony-service │ default │ 1.0.0 │ cluster │ 373 │ 0s │ 0 │ online │ 0% │ 41.8mb │ cci │ disabled │
│ 2 │ nodefony-service │ default │ 1.0.0 │ cluster │ 374 │ 0s │ 0 │ online │ 0% │ 36.9mb │ cci │ disabled │
│ 3 │ nodefony-service │ default │ 1.0.0 │ cluster │ 378 │ 0s │ 0 │ online │ 0% │ 33.1mb │ cci │ disabled │
│ 4 │ nodefony-service │ default │ 1.0.0 │ cluster │ 382 │ 0s │ 0 │ online │ 0% │ 25.7mb │ cci │ disabled │
│ 5 │ nodefony-service │ default │ 1.0.0 │ cluster │ 398 │ 0s │ 0 │ online │ 0% │ 26.8mb │ cci │ disabled │
│ 6 │ nodefony-service │ default │ 1.0.0 │ cluster │ 403 │ 0s │ 0 │ online │ 0% │ 23.2mb │ cci │ disabled │
│ 7 │ nodefony-service │ default │ 1.0.0 │ cluster │ 412 │ 0s │ 0 │ online │ 0% │ 23.1mb │ cci │ disabled │
└─────┴─────────────────────┴─────────────┴─────────┴─────────┴──────────┴────────┴──────┴───────────┴──────────┴──────────┴──────────┴──────────┘
[PM2][WARN] Current process list running is not in sync with saved list. cci differs. Type 'pm2 save' to synchronize.
const nodefony = require("nodefony");
const path = require("path");
const Server = require(path.resolve("src", "node", "services", "servers", "http.js"));
class Service extends nodefony.Service {
constructor(environment = "production", debug = false) {
super("Microservice");
this.environment = environment;
this.debug = debug;
// init logger
this.initSyslog();
this.log(`Environment = ${environment} Debug = ${debug}`);
this.settings = require(path.resolve("config", "config.js"));
// start
this.start();
}
async start() {
return await this.startHttpServer();
}
async startHttpServer(){
const http = new Server(this);
// add in service container
this.set("http", http);
return await http.start();
}
stop(code) {
return new Promise((resolve, reject)=>{
process.nextTick(() => {
this.log("Life Cycle Terminate");
try {
if (code === 0) {
process.exitCode = code;
}
return resolve(process.exit(code));
} catch (e) {
this.log(e, "ERROR");
return reject(e);
}
});
});
}
}
module.exports = new Service(process.env.NODE_ENV, process.env.DEBUG);
$ npm run prod
_ _ _
_ __ _ __ ___ __| | _ _ ___ | |_ (_) ___ _ __
| '_ \ | '__| / _ \ / _` | | | | | / __| | __| | | / _ \ | '_ \
| |_) | | | | (_) | | (_| | | |_| | | (__ | |_ | | | (_) | | | | |
| .__/ |_| \___/ \__,_| \__,_| \___| \__| |_| \___/ |_| |_|
|_|
Version : 1.0.0 Platform : darwin Process : nodefony-service Pid : 87126
Sun Mar 08 2020 22:10:24 INFO COMMAND : production
Sun Mar 08 2020 22:10:24 INFO nodefony-service : Command : npm run prod in cwd : /Users/christophecamensuli/repository/test/nodefony-service
Sun Mar 08 2020 22:10:24 INFO nodefony-service : Spawn : npm run prod
npm WARN lifecycle The node binary used for scripts is /var/folders/h_/6my946zd5bz1w8wtz8s69yxh0000gn/T/yarn--1583701819977-0.23551390273035233/node but npm is using /Users/christophecamensuli/.nvm/versions/node/v13.9.0/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.
> nodefony-service@1.0.0 prod /Users/christophecamensuli/repository/test/nodefony-service
> env-cmd -e production pm2 start config/pm2.config.js --env production
┌─────┬─────────────────────┬─────────────┬─────────┬─────────┬──────────┬────────┬──────┬───────────┬──────────┬──────────┬──────────┬──────────┐
│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │
├─────┼─────────────────────┼─────────────┼─────────┼─────────┼──────────┼────────┼──────┼───────────┼──────────┼──────────┼──────────┼──────────┤
│ 2 │ examples │ default │ 1.0.0 │ cluster │ 87135 │ 2s │ 0 │ online │ 0% │ 57.4mb │ chr… │ disabled │
│ 4 │ examples │ default │ 1.0.0 │ cluster │ 87137 │ 2s │ 0 │ online │ 0% │ 57.0mb │ chr… │ disabled │
│ 6 │ examples │ default │ 1.0.0 │ cluster │ 87139 │ 2s │ 0 │ online │ 0% │ 53.0mb │ chr… │ disabled │
│ 8 │ examples │ default │ 1.0.0 │ cluster │ 87141 │ 1s │ 0 │ online │ 0% │ 49.4mb │ chr… │ disabled │
│ 11 │ examples │ default │ 1.0.0 │ cluster │ 87168 │ 1s │ 0 │ online │ 0% │ 49.3mb │ chr… │ disabled │
│ 13 │ examples │ default │ 1.0.0 │ cluster │ 87174 │ 1s │ 0 │ online │ 0% │ 44.7mb │ chr… │ disabled │
│ 15 │ examples │ default │ 1.0.0 │ cluster │ 87180 │ 1s │ 0 │ online │ 0% │ 45.8mb │ chr… │ disabled │
│ 17 │ examples │ default │ 1.0.0 │ cluster │ 87182 │ 1s │ 0 │ online │ 0% │ 43.2mb │ chr… │ disabled │
│ 19 │ examples │ default │ 1.0.0 │ cluster │ 87188 │ 1s │ 0 │ online │ 0% │ 42.2mb │ chr… │ disabled │
│ 21 │ examples │ default │ 1.0.0 │ cluster │ 87196 │ 1s │ 0 │ online │ 0% │ 39.0mb │ chr… │ disabled │
│ 23 │ examples │ default │ 1.0.0 │ cluster │ 87200 │ 1s │ 0 │ online │ 0% │ 37.8mb │ chr… │ disabled │
│ 24 │ examples │ default │ 1.0.0 │ cluster │ 87203 │ 1s │ 0 │ online │ 0% │ 38.6mb │ chr… │ disabled │
│ 1 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87134 │ 2s │ 0 │ online │ 0% │ 57.8mb │ chr… │ disabled │
│ 3 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87136 │ 2s │ 0 │ online │ 0% │ 56.7mb │ chr… │ disabled │
│ 5 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87138 │ 2s │ 0 │ online │ 0% │ 53.6mb │ chr… │ disabled │
│ 7 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87140 │ 1s │ 0 │ online │ 0% │ 50.1mb │ chr… │ disabled │
│ 9 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87153 │ 1s │ 0 │ online │ 0% │ 48.6mb │ chr… │ disabled │
│ 10 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87167 │ 1s │ 0 │ online │ 0% │ 50.1mb │ chr… │ disabled │
│ 12 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87173 │ 1s │ 0 │ online │ 0% │ 47.3mb │ chr… │ disabled │
│ 14 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87175 │ 1s │ 0 │ online │ 0% │ 47.7mb │ chr… │ disabled │
│ 16 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87181 │ 1s │ 0 │ online │ 0% │ 44.2mb │ chr… │ disabled │
│ 18 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87187 │ 1s │ 0 │ online │ 0% │ 42.0mb │ chr… │ disabled │
│ 20 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87195 │ 1s │ 0 │ online │ 0% │ 40.9mb │ chr… │ disabled │
│ 22 │ nodefony-service │ default │ 1.0.0 │ cluster │ 87199 │ 1s │ 0 │ online │ 0% │ 41.0mb │ chr… │ disabled │
└─────┴─────────────────────┴─────────────┴─────────┴─────────┴──────────┴────────┴──────┴───────────┴──────────┴──────────┴──────────┴──────────┘
Module
┌────┬───────────────────────────────────────┬────────────────────┬───────┬──────────┬──────┬──────────┬──────────┬──────────┐
│ id │ module │ version │ pid │ status │ ↺ │ cpu │ mem │ user │
├────┼───────────────────────────────────────┼────────────────────┼───────┼──────────┼──────┼──────────┼──────────┼──────────┤
│ 0 │ pm2-logrotate │ 2.7.0 │ 87131 │ online │ 0 │ 0% │ 47.1mb │ chr… │
└────┴───────────────────────────────────────┴────────────────────┴───────┴──────────┴──────┴──────────┴──────────┴──────────┘
✨ Done in 7.29s.
$ npm run log
/Users/.pm2/logs/pm2-logrotate-error.log last 15 lines:
/Users/.pm2/logs/pm2-logrotate-out.log last 15 lines:
0|pm2-logr | "/Users/.pm2/logs/pm2-logrotate-out__2020-03-05_00-28-49.log" has been created
0|pm2-logr | "/Users/repository/test/nodefony-service/tmp/nodefony-service__2020-03-05_00-28-49.log" has been created
/Users/repository/test/nodefony-service/tmp/nodefony-service.log last 15 lines:
1|nodefony | Sun Mar 08 2020 22:10:30 INFO SERVICE Markdown : Running
1|nodefony | Sun Mar 08 2020 22:10:30 INFO SERVICE HTTP Server : Starting Server
1|nodefony | Sun Mar 08 2020 22:10:30 INFO SERVICE Markdown : Running
1|nodefony | Sun Mar 08 2020 22:10:30 INFO SERVICE HTTP Server : Starting Server
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTP Server : Server running at http://127.0.0.1:3000/
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTPS Server : Starting Server HTTPS
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTPS Server : Server running at http://127.0.0.1:3443/
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTP Server : Server running at http://127.0.0.1:3000/
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTPS Server : Starting Server HTTPS
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTPS Server : Server running at http://127.0.0.1:3443/
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE Markdown : Running
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTP Server : Starting Server
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTP Server : Server running at http://127.0.0.1:3000/
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTPS Server : Starting Server HTTPS
1|nodefony | Sun Mar 08 2020 22:10:31 INFO SERVICE HTTPS Server : Server running at http://127.0.0.1:3443/
/Users/repository/test/nodefony-service/tmp/examples.log last 15 lines:
2|examples | Sun Mar 08 2020 22:10:31 INFO SERVICE n-api : world
2|examples | Sun Mar 08 2020 22:10:31 DEBUG SERVICE syscall : Child Process exited with code 0
2|examples | Sun Mar 08 2020 22:10:31 INFO SERVICE n-api : Running
2|examples | Sun Mar 08 2020 22:10:31 INFO SERVICE n-api : world
2|examples | Sun Mar 08 2020 22:10:31 INFO SERVICE n-api : Running
2|examples | Sun Mar 08 2020 22:10:31 INFO SERVICE n-api : world
2|examples | Sun Mar 08 2020 22:10:31 INFO SERVICE n-api : Running
2|examples | Sun Mar 08 2020 22:10:31 INFO SERVICE n-api : world
2|examples | Sun Mar 08 2020 22:10:32 INFO SERVICE socket-io : connection : WtYW1dxYlLVTAZgiAAAA
2|examples | Sun Mar 08 2020 22:10:35 INFO SERVICE socket-io : connection : fPfmwvwT15VxmdtlAAAA
2|examples | Sun Mar 08 2020 22:10:38 INFO SERVICE socket-io : send after 5 s
2|examples | Sun Mar 08 2020 22:10:41 INFO SERVICE socket-io : send after 5 s
2|examples | Sun Mar 08 2020 22:11:34 INFO SERVICE socket-io : disconnect : WtYW1dxYlLVTAZgiAAAA
2|examples | Sun Mar 08 2020 22:11:36 INFO SERVICE socket-io : connection : YP-GTKP0mrC-UaqvAAAA
2|examples | Sun Mar 08 2020 22:11:44 INFO SERVICE socket-io : send after 5 s
┌─ Process List ─────────────────────────────────────────────┐┌── examples Logs ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
│[ 2] examples Mem: 56 MB CPU: 0 % online ││ examples > Sun Mar 08 2020 22:17:28 INFO SERVICE socket-io : disconnect : fPfmwvwT15VxmdtlAAAA │
│[ 4] examples Mem: 59 MB CPU: 0 % online ││ examples > Sun Mar 08 2020 22:17:40 INFO SERVICE Microservice : 200 url : http://127.0.0.1:3001/ │
│[ 6] examples Mem: 58 MB CPU: 0 % online ││ examples > Sun Mar 08 2020 22:17:41 INFO SERVICE Microservice : 200 url : http://127.0.0.1:3001/ │
│[ 8] examples Mem: 59 MB CPU: 0 % online ││ │
│[11] examples Mem: 54 MB CPU: 0 % online ││ │
│[13] examples Mem: 58 MB CPU: 0 % online ││ │
│[15] examples Mem: 56 MB CPU: 0 % online ││ │
│[17] examples Mem: 55 MB CPU: 0 % online ││ │
│[19] examples Mem: 58 MB CPU: 0 % online ││ │
│[21] examples Mem: 54 MB CPU: 1 % online ││ │
│[23] examples Mem: 57 MB CPU: 1 % online ││ │
│[24] examples Mem: 59 MB CPU: 0 % online ││ │
│[ 1] nodefony-service Mem: 60 MB CPU: 0 % online ││ │
│[ 3] nodefony-service Mem: 58 MB CPU: 0 % online ││ │
│[ 5] nodefony-service Mem: 57 MB CPU: 0 % online ││ │
│[ 7] nodefony-service Mem: 59 MB CPU: 1 % online ││ │
│[ 9] nodefony-service Mem: 59 MB CPU: 1 % online ││ │
│[10] nodefony-service Mem: 59 MB CPU: 0 % online ││ │
│[12] nodefony-service Mem: 57 MB CPU: 1 % online ││ │
│[14] nodefony-service Mem: 59 MB CPU: 1 % online ││ │
│[16] nodefony-service Mem: 58 MB CPU: 0 % online ││ │
│[18] nodefony-service Mem: 58 MB CPU: 0 % online ││ │
│[20] nodefony-service Mem: 58 MB CPU: 0 % online ││ │
│[22] nodefony-service Mem: 58 MB CPU: 0 % online ││ │
│[ 0] pm2-logrotate Mem: 49 MB CPU: 1 % online ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
│ ││ │
└────────────────────────────────────────────────────────────┘└───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
┌─ Custom Metrics ───────────────────────────────────────────┐┌─ Metadata ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
│ Heap Size 29.54 MiB ││ App Name examples │
│ Heap Usage 91.78 % ││ Namespace default │
│ Used Heap Size 27.11 MiB ││ Version 1.0.0 │
│ Active requests 0 ││ Restarts 0 │
│ Active handles 1 ││ Uptime 9m │
│ Event Loop Latency 1.43 ms ││ Script path /Users/christophecamensuli/repository/test/nodefony-service/src/node/examples/index.js │
│ Event Loop Latency p95 5.18 ms ││ Script args pm2 │
│ HTTP Mean Latency 1.5 ms ││ Interpreter node │
│ HTTP P95 Latency 2 ms ││ Interpreter args N/A │
│ HTTP 0.01 req/min ││ Exec mode cluster │
│ ││ Node.js version 13.9.0 │
│ ││ watch & reload ✘ │
│ ││ Unstable restarts 0 │
└────────────────────────────────────────────────────────────┘└───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
left/right: switch boards | up/down/mouse: scroll | Ctrl-C: exit To go further check out https://pm2.io/