Skip to content

Instantly share code, notes, and snippets.

@mgarciap
Created April 13, 2019 14:14
Show Gist options
  • Save mgarciap/b783269c10f4bf626d2cfeaf98385284 to your computer and use it in GitHub Desktop.
Save mgarciap/b783269c10f4bf626d2cfeaf98385284 to your computer and use it in GitHub Desktop.
Docker version 18.09.5
Compose version 1.24.0
-------------
__/\\\\\\\\\\\\\____/\\\\____________/\\\\____/\\\\\\\\\_____
_\/\\\/////////\\\_\/\\\\\\________/\\\\\\__/\\\///////\\\___
_\/\\\_______\/\\\_\/\\\//\\\____/\\\//\\\_\///______\//\\\__
_\/\\\\\\\\\\\\\/__\/\\\\///\\\/\\\/_\/\\\___________/\\\/___
_\/\\\/////////____\/\\\__\///\\\/___\/\\\________/\\\//_____
_\/\\\_____________\/\\\____\///_____\/\\\_____/\\\//________
_\/\\\_____________\/\\\_____________\/\\\___/\\\/___________
_\/\\\_____________\/\\\_____________\/\\\__/\\\\\\\\\\\\\\\_
_\///______________\///______________\///__\///////////////__
Runtime Edition
PM2 is a Production Process Manager for Node.js applications
with a built-in Load Balancer.
Start and Daemonize any application:
$ pm2 start app.js
Load Balance 4 instances of api.js:
$ pm2 start api.js -i 4
Monitor in production:
$ pm2 monitor
Make pm2 auto-boot at server restart:
$ pm2 startup
To go further checkout:
http://pm2.io/
-------------
pm2 launched in no-daemon mode (you can add DEBUG="*" env variable to get more messages)
2019-04-13T14:08:06: PM2 log: Launching in no daemon mode
2019-04-13T14:08:06: PM2 log: [PM2][WARN] Applications worker not running, starting...
2019-04-13T14:08:06: PM2 log: [Watch] Start watching worker
2019-04-13T14:08:06: PM2 log: App [worker:0] starting in -fork mode-
2019-04-13T14:08:06: PM2 log: App [worker:0] online
2019-04-13T14:08:06: PM2 log: [PM2] App [worker] launched (1 instances)
2019-04-13T14:08:07: PM2 log: ┌──────────┬────┬─────────┬──────┬─────┬────────┬─────────┬────────┬─────┬───────────┬──────┬──────────┐
│ App name │ id │ version │ mode │ pid │ status │ restart │ uptime │ cpu │ mem │ user │ watching │
├──────────┼────┼─────────┼──────┼─────┼────────┼─────────┼────────┼─────┼───────────┼──────┼──────────┤
│ worker │ 0 │ 0.1.4 │ fork │ 16 │ online │ 0 │ 0s │ 0% │ 24.2 MB │ root │ enabled │
└──────────┴────┴─────────┴──────┴─────┴────────┴─────────┴────────┴─────┴───────────┴──────┴──────────┘
2019-04-13T14:08:07: PM2 log: Use `pm2 show <id|name>` to get more details about an app
2019-04-13T14:08:07: PM2 log: [--no-daemon] Continue to stream logs
2019-04-13T14:08:07: PM2 log: [--no-daemon] Exit on target PM2 exit pid=1
14:08:17 0|worker | Sat, 13 Apr 2019 14:08:17 GMT sequelize deprecated String based operators are now deprecated. Please use Symbol based operators for better security, read more at http://docs.sequelizejs.com/manual/tutorial/querying.html#operators at node_modules/sequelize/lib/sequelize.js:242:13
14:08:17 0|worker | (node:16) ExperimentalWarning: The fs.promises API is experimental
14:08:20 0|worker | Sequelize CLI [Node: 10.15.3, CLI: 5.4.0, ORM: 4.41.2]
14:08:20 0|worker | Loaded configuration file "lib/sequelize_config.js".
14:08:20 0|worker | Using environment "development".
14:08:20 0|worker | Sat, 13 Apr 2019 14:08:20 GMT sequelize deprecated String based operators are now deprecated. Please use Symbol based operators for better security, read more at http://docs.sequelizejs.com/manual/tutorial/querying.html#operators at node_modules/sequelize/lib/sequelize.js:242:13
14:08:21 0|worker | No migrations were executed, database schema was already up to date.
14:08:21 0|worker | API listening on port 8443
14:08:25 0|worker | Warped to block 7525000
14:08:25 0|worker | Processing blocks 7525000 to 7525009
14:08:25 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:08:35 0|worker | Error processing transactions, retry in 5 seconds
14:08:40 0|worker | Processing blocks 7525000 to 7525009
14:08:50 0|worker | Processing blocks 7525010 to 7525019
14:08:55 0|worker | Error fetching blocks, retry in 5 seconds
14:08:55 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:09:00 0|worker | Processing blocks 7525010 to 7525019
14:09:08 0|worker | Error processing transactions, retry in 5 seconds
14:09:13 0|worker | Processing blocks 7525010 to 7525019
14:09:20 0|worker | Error processing transactions, retry in 5 seconds
14:09:25 0|worker | Processing blocks 7525010 to 7525019
14:09:25 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:09:28 0|worker | Processing blocks 7525020 to 7525029
14:09:37 0|worker | Processing blocks 7525030 to 7525039
14:09:42 0|worker | Error fetching blocks, retry in 5 seconds
14:09:47 0|worker | Processing blocks 7525030 to 7525039
14:09:52 0|worker | Processing blocks 7525040 to 7525049
14:09:55 0|worker | Processing blocks 7525050 to 7525059
14:09:55 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:10:01 0|worker | Processing blocks 7525060 to 7525069
14:10:04 0|worker | Processing blocks 7525070 to 7525079
14:10:11 0|worker | Processing blocks 7525080 to 7525089
14:10:19 0|worker | Processing blocks 7525090 to 7525099
14:10:23 0|worker | Processing blocks 7525100 to 7525109
14:10:25 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:10:30 0|worker | Processing blocks 7525110 to 7525119
14:10:36 0|worker | Processing blocks 7525120 to 7525129
14:10:40 0|worker | Processing blocks 7525130 to 7525139
14:10:47 0|worker | Processing blocks 7525140 to 7525149
14:10:51 0|worker | Processing blocks 7525150 to 7525159
14:10:55 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:10:56 0|worker | Processing blocks 7525160 to 7525169
14:10:58 0|worker | Processing blocks 7525170 to 7525179
14:11:03 0|worker | Processing blocks 7525180 to 7525189
14:11:06 0|worker | Processing blocks 7525190 to 7525199
14:11:14 0|worker | Processing blocks 7525200 to 7525209
14:11:21 0|worker | Processing blocks 7525210 to 7525219
14:11:25 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:11:31 0|worker | Processing blocks 7525220 to 7525229
14:11:38 0|worker | Processing blocks 7525230 to 7525239
14:11:46 0|worker | Processing blocks 7525240 to 7525249
14:11:53 0|worker | Processing blocks 7525250 to 7525259
14:11:55 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:12:00 0|worker | Processing blocks 7525260 to 7525269
14:12:08 0|worker | Processing blocks 7525270 to 7525279
14:12:15 0|worker | Processing blocks 7525280 to 7525289
14:12:24 0|worker | Processing blocks 7525290 to 7525299
14:12:25 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:12:29 0|worker | Processing blocks 7525300 to 7525309
14:12:33 0|worker | Processing blocks 7525310 to 7525319
14:12:37 0|worker | Processing blocks 7525320 to 7525329
14:12:45 0|worker | Processing blocks 7525330 to 7525339
14:12:49 0|worker | Processing blocks 7525340 to 7525349
14:12:55 0|worker | Processing blocks 7525350 to 7525359
14:12:55 0|worker | STAKING OFFLINE: Your staker is out of sync with the blockchain
14:13:03 0|worker | Processing blocks 7525360 to 7525369
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment