You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+55-19Lines changed: 55 additions & 19 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,15 +27,15 @@
27
27
<br/>
28
28
</div>
29
29
30
-
PM2 is a production process manager for Node.js applications with a built-in load balancer. It allows you to keep applications alive forever, to reload them without downtime and to facilitate common system admin tasks.
30
+
PM2 is a Production Runtime and Process Manager for Node.js applications with a built-in Load Balancer. It allows you to keep applications alive forever, to reload them without downtime and facilitate common Devops tasks.
31
31
32
32
Starting an application in production mode is as easy as:
33
33
34
34
```bash
35
35
$ pm2 start app.js
36
36
```
37
37
38
-
PM2 is constantly assailed by [more than 1400 tests](https://travis-ci.org/Unitech/pm2).
38
+
PM2 is constantly assailed by [more than 1800 tests](https://travis-ci.org/Unitech/pm2).
39
39
40
40
Official website: [http://pm2.keymetrics.io/](http://pm2.keymetrics.io/)
41
41
@@ -64,9 +64,10 @@ Your app is now daemonized, monitored and kept alive forever.
64
64
65
65
## Container Support
66
66
67
-
Using Containers? We got your back with pm2-runtime, a dedicated command for running Node.js in containers and our [officialy suported Docker image](https://hub.docker.com/r/keymetrics/pm2/).
67
+
Using Containers? With the dropin replacement command for `node`, called `pm2-runtime`, run your Node.js application in the best production environment.
68
+
We also offer an [officialy suported Docker image](https://hub.docker.com/r/keymetrics/pm2/).
Also check out the [example folder](https://github.com/Unitech/pm2/tree/master/examples) to discover all features.
168
+
165
169
### Process management
166
170
167
171
Once applications are started you can list and manage them easily:
@@ -174,17 +178,13 @@ Listing all running processes:
174
178
$ pm2 list
175
179
```
176
180
177
-
Managing your processes is straightforward:
181
+
Managing processes is straightforward:
178
182
179
183
```bash
180
184
$ pm2 stop <app_name|id|'all'|json_conf>
181
185
$ pm2 restart <app_name|id|'all'|json_conf>
182
186
$ pm2 delete <app_name|id|'all'|json_conf>
183
187
```
184
-
To make sure it re-evaluates enviroment variables declared in your `json_conf` pass it as argument, and optionally your custom `env` name from your `json_conf` if any:
185
-
```bash
186
-
$ pm2 restart <json_conf> [--env <env_name>]
187
-
```
188
188
189
189
To have more details on a specific process:
190
190
@@ -196,9 +196,9 @@ $ pm2 describe <id|app_name>
196
196
197
197
### Load Balancing & Zero second Downtime Reload
198
198
199
-
When an application is started with the -i <instance_number> option, the **Cluster Mode** is enabled.
199
+
When an application is started with the -i <instance_number> parameter, the **Cluster Mode** is activated.
200
200
201
-
The Cluster Mode starts <instance_number> instances of your app and automatically load balance HTTP/TCP/UDP between each instance. This allows to increase overall performance depending on the number of CPUs available.
201
+
The Cluster Mode starts <instance_number> instances of your app and automatically load balance HTTP/TCP/UDP between each instances. This allows to increase overall performance and reliability depending on the number of CPUs available.
202
202
203
203
Seamlessly supported by all major Node.js frameworks and any Node.js applications without any code change:
204
204
@@ -207,16 +207,19 @@ Seamlessly supported by all major Node.js frameworks and any Node.js application
207
207
Main commands:
208
208
209
209
```bash
210
-
$ pm2 start app.js -i max # Enable load-balancer and start 'max' instances (cpu nb)
210
+
# Enable load-balancer and start 'max' instances (Depending on CPU number)
211
+
$ pm2 start app.js -i max
211
212
212
-
$ pm2 reload all # Zero second dowtime reload
213
+
# Update your application with Zero Downtime Reload (requests are not lost)
214
+
$ pm2 reload all
213
215
214
-
$ pm2 scale <app_name><instance_number># Increase / Decrease process number
216
+
# Increase / Decrease process number
217
+
$ pm2 scale <app_name><instance_number>
215
218
```
216
219
217
220
[More informations about how PM2 make clustering easy](https://keymetrics.io/2015/03/26/pm2-clustering-made-easy/)
0 commit comments