1 | # PM2 production process manager
|
2 |
|
3 | ## Table of contents
|
4 |
|
5 | ### Quick start
|
6 |
|
7 | - [Installation](#a1)
|
8 | - [How to update PM2?](#update-pm2)
|
9 | - [PM2 tab-completion](#tab-completion)
|
10 | - [Allow PM2 to bind apps on port 80/443 without root](#authbind-pm2)
|
11 |
|
12 | ### Features
|
13 |
|
14 | - [Transitional state of apps](#a4)
|
15 | - [Process listing](#a6)
|
16 | - [Automatic restart process based on memory](#max-memory-restart)
|
17 | - [Monitoring CPU/Memory usage](#a7)
|
18 | - [Logs management](#a9)
|
19 | - [Clustering](#a5)
|
20 | - [Multiple PM2 on the same server](#multiple-pm2)
|
21 | - [Watch & Restart](#watch--restart)
|
22 | - [Reloading without downtime](#hot-reload--0s-reload)
|
23 | - [Make PM2 restart on server reboot](#a8)
|
24 | - [JS/JSON app declaration](#jsjson-app-declaration)
|
25 | - [Options list](#list-of-all-json-declaration-fields-avaibles)
|
26 | - [Schema](#schema)
|
27 | - [Using PM2 in development](#using-pm2-in-development)
|
28 | - [Use ES6](#run-next-generation-javascript)
|
29 |
|
30 | ### [Using PM2 in Cloud Providers (Heroku/Google App Engine/Azure)](https://github.com/Unitech/PM2/blob/development/ADVANCED_README.md#using-pm2-in-cloud-providers-1)
|
31 |
|
32 | - [Without Keymetrics](#without-keymetrics)
|
33 | - [With Keymetrics](#with-keymetrics)
|
34 |
|
35 | ### Deployment - ecosystem.json
|
36 |
|
37 | - [Getting started with deployment](#deployment)
|
38 | - [Deployment options](#deployment-help)
|
39 | - [Considerations](#considerations)
|
40 | - [Contributing](#deployment-contribution)
|
41 |
|
42 | ### Using PM2 programmatically (via API)
|
43 |
|
44 | - [Simple example](#programmatic-example)
|
45 | - [Programmatic API](#programmatic-api)
|
46 |
|
47 | ### Specific
|
48 |
|
49 | - [Specific features](#a77)
|
50 | - [Configuration file](#a989)
|
51 | - [Enabling Harmony ES6](#a66)
|
52 | - [CoffeeScript](#a19)
|
53 | - [Testing PM2 on your prod environment](#a149)
|
54 | - [JSON app via pipe](#a96)
|
55 |
|
56 | ### Knowledge
|
57 |
|
58 | - [Stateless apps ?](#stateless-apps)
|
59 | - [Transitional state of apps](#a4)
|
60 | - [Setup PM2 on server: tutorial](#a89)
|
61 | - [Logs and PID files](#a34)
|
62 | - [Execute any script: What is fork mode ?](#a23)
|
63 |
|
64 | ### More
|
65 |
|
66 | - [Contributing/Development mode](#a27)
|
67 | - [Known bugs and workaround](#a21)
|
68 | - [They talk about it](#a20)
|
69 | - [License](#a15)
|
70 |
|
71 | ------
|
72 |
|
73 | # Quick start
|
74 |
|
75 | <a name="a1"/>
|
76 | ## Installation
|
77 |
|
78 | [Quick Start](http://pm2.keymetrics.io/docs/usage/quick-start/)
|
79 |
|
80 | <a name="update-pm2"/>
|
81 | ## How to update PM2
|
82 |
|
83 | [Update PM2](http://pm2.keymetrics.io/docs/usage/quick-start/#how-to-update-pm2)
|
84 |
|
85 | <a name="tab-completion"/>
|
86 | ## PM2 tab-completion
|
87 |
|
88 | [Tab-completion for pm2](http://pm2.keymetrics.io/docs/usage/auto-completion/)
|
89 |
|
90 | # Features
|
91 |
|
92 | <a name="a4"/>
|
93 | ## Managing applications states
|
94 |
|
95 | [Process Management](http://pm2.keymetrics.io/docs/usage/process-management/)
|
96 |
|
97 | <a name="a6"/>
|
98 | ## Process listing
|
99 |
|
100 | [Process Listing](http://pm2.keymetrics.io/docs/usage/process-management/#process-listing)
|
101 |
|
102 | <a name="a7"/>
|
103 | ## Monitoring CPU/Memory
|
104 |
|
105 | [Monitoring](http://pm2.keymetrics.io/docs/usage/monitoring/)
|
106 |
|
107 | <a name="a5"/>
|
108 | ## Clustering
|
109 |
|
110 | [Cluster mode](http://pm2.keymetrics.io/docs/usage/cluster-mode/)
|
111 |
|
112 | ### Hot reload / 0s reload
|
113 |
|
114 | [Reload without Downtime](http://pm2.keymetrics.io/docs/usage/cluster-mode/#reload-without-downtime)
|
115 |
|
116 | ### Graceful reload
|
117 |
|
118 | [Graceful Reload](http://pm2.keymetrics.io/docs/usage/cluster-mode/#graceful-reload)
|
119 |
|
120 | <a name="a9"/>
|
121 | ## Logs management
|
122 |
|
123 | [Log Management](http://pm2.keymetrics.io/docs/usage/log-management/)
|
124 |
|
125 | <a name="max-memory-restart"/>
|
126 | ## Max Memory Restart
|
127 |
|
128 | [Max Memory Restart](http://pm2.keymetrics.io/docs/usage/monitoring/#max-memory-restart)
|
129 |
|
130 | <a name="a8"/>
|
131 | ## Startup script
|
132 |
|
133 | [Startup Script](http://pm2.keymetrics.io/docs/usage/startup/)
|
134 |
|
135 | ## Multiple PM2 on the same server
|
136 |
|
137 | [Multiple PM2](http://pm2.keymetrics.io/docs/usage/specifics/#multiple-pm2-on-the-same-server)
|
138 |
|
139 | ## Watch & Restart
|
140 |
|
141 | [Watch and Restart](http://pm2.keymetrics.io/docs/usage/watch-and-restart/)
|
142 |
|
143 | ## JS/JSON app declaration
|
144 |
|
145 | [Application Declaration](http://pm2.keymetrics.io/docs/usage/application-declaration/)
|
146 |
|
147 | ## Using PM2 in development
|
148 |
|
149 | [PM2 in Development](http://pm2.keymetrics.io/docs/usage/pm2-development/)
|
150 |
|
151 | ## Run Next generation Javascript
|
152 |
|
153 | [Run ES6](http://pm2.keymetrics.io/docs/usage/specifics/#enabling-harmony-es6)
|
154 |
|
155 | # Using PM2 in Cloud Providers
|
156 |
|
157 | [Using PM2 with PaaS](http://pm2.keymetrics.io/docs/usage/use-pm2-with-cloud-providers/)
|
158 |
|
159 | <a name="deployment"/>
|
160 | # Deployment
|
161 |
|
162 | [Deployment](http://pm2.keymetrics.io/docs/usage/deployment/)
|
163 |
|
164 | <a name="programmatic-example"/>
|
165 | # Using PM2 programmatically
|
166 |
|
167 | [PM2 API](http://pm2.keymetrics.io/docs/usage/pm2-api/)
|
168 |
|
169 | <a name="a77"/>
|
170 | # Special features
|
171 |
|
172 | [Specifics](http://pm2.keymetrics.io/docs/usage/specifics/)
|
173 |
|
174 | <a name="a66"/>
|
175 | ## Enabling Harmony ES6
|
176 |
|
177 | [Specifics](http://pm2.keymetrics.io/docs/usage/specifics/)
|
178 |
|
179 | <a name="a19"/>
|
180 | ## CoffeeScript
|
181 |
|
182 | [Specifics](http://pm2.keymetrics.io/docs/usage/specifics/)
|
183 |
|
184 | # Knowledge
|
185 |
|
186 | [Knowledge](http://pm2.keymetrics.io/docs/usage/knowledge/)
|
187 |
|
188 | # Contributing
|
189 |
|
190 | [Contributing](http://pm2.keymetrics.io/docs/usage/contributing/)
|
191 |
|
192 | ### User tips from issues
|
193 | - [Vagrant and pm2 #289](https://github.com/Unitech/pm2/issues/289#issuecomment-42900019)
|
194 | - [Start the same app on different ports #322](https://github.com/Unitech/pm2/issues/322#issuecomment-46792733)
|
195 | - [Using ansible with pm2](https://github.com/Unitech/pm2/issues/88#issuecomment-49106686)
|
196 | - [Cron string as argument](https://github.com/Unitech/pm2/issues/496#issuecomment-49323861)
|
197 | - [Restart when process reaches a specific memory amount](https://github.com/Unitech/pm2/issues/141)
|
198 | - [Sticky sessions and socket.io discussion](https://github.com/Unitech/PM2/issues/637)
|
199 | - [EACCESS - understanding pm2 user/root rights](https://github.com/Unitech/PM2/issues/837)
|
200 |
|
201 | <a name="a20"/>
|
202 | ## External resources and articles
|
203 |
|
204 | - [Goodbye node-forever, hello pm2](http://devo.ps/blog/goodbye-node-forever-hello-pm2/)
|
205 | - [https://serversforhackers.com/editions/2014/11/04/pm2/](https://serversforhackers.com/editions/2014/11/04/pm2/)
|
206 | - http://www.allaboutghost.com/keep-ghost-running-with-pm2/
|
207 | - http://blog.ponyfoo.com/2013/09/19/deploying-node-apps-to-aws-using-grunt
|
208 | - http://www.allaboutghost.com/keep-ghost-running-with-pm2/
|
209 | - http://bioselemental.com/keeping-ghost-alive-with-pm2/
|
210 | - http://blog.chyld.net/installing-ghost-on-ubuntu-13-10-aws-ec2-instance-with-pm2/
|
211 | - http://blog.marvinroger.fr/gerer-ses-applications-node-en-production-pm2/
|
212 | - https://www.codersgrid.com/2013/06/29/pm2-process-manager-for-node-js/
|
213 | - http://www.z-car.com/blog/programming/how-to-rotate-logs-using-pm2-process-manager-for-node-js
|
214 | - http://yosoftware.com/blog/7-tips-for-a-node-js/
|
215 | - https://www.exponential.io/blog/nodeday-2014-moving-a-large-developer-workforce-to-nodejs
|
216 | - http://blog.rapsli.ch/posts/2013/2013-10-17-node-monitor-pm2.html
|
217 | - https://coderwall.com/p/igdqyw
|
218 | - http://revdancatt.com/2013/09/17/node-day-1-getting-the-server-installing-node-and-pm2/
|
219 | - https://medium.com/tech-talk/e7c0b0e5ce3c
|
220 |
|
221 | ## Contributors
|
222 |
|
223 | [Contributors](http://pm2.keymetrics.io/hall-of-fame/)
|
224 |
|
225 | ## Sponsors
|
226 |
|
227 | Thanks to [Devo.ps](http://devo.ps/) and [Wiredcraft](http://wiredcraft.com/) for their knowledge and expertise.
|
228 |
|
229 | <a name="a15"/>
|
230 | # License
|
231 |
|
232 | Files in `lib/` are made available under the terms of the GNU Affero General Public License 3.0 (AGPL 3.0).
|
233 | Except the file `lib/CLI.js` who is made under the terms of the Apache V2 license.
|