From 59af0b4b6e94e74b37f5a2888d49f575dc78ae24 Mon Sep 17 00:00:00 2001 From: Larry Marburger Date: Tue, 16 Jul 2013 16:00:15 -0400 Subject: [PATCH 1/5] Link to status.rb --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 0a1c3d58..ced38780 100644 --- a/README.md +++ b/README.md @@ -141,7 +141,7 @@ Puma comes with a builtin status/control app that can be used query and control $ puma --control tcp://127.0.0.1:9293 --control-token foo -This directs puma to start the control server on localhost port 9293. Additionally, all requests to the control server will need to include `token=foo` as a query parameter. This allows for simple authentication. Check out https://github.com/puma/puma/blob/master/lib/puma/app/status.rb to see what the app has available. +This directs puma to start the control server on localhost port 9293. Additionally, all requests to the control server will need to include `token=foo` as a query parameter. This allows for simple authentication. Check out [status.rb](https://github.com/puma/puma/blob/master/lib/puma/app/status.rb) to see what the app has available. ### Configuration file From 0f3ae82475bde3bbb9d2fa5951941d60f8186b2a Mon Sep 17 00:00:00 2001 From: Larry Marburger Date: Tue, 16 Jul 2013 16:01:47 -0400 Subject: [PATCH 2/5] Call out -C/--config flags --- README.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/README.md b/README.md index ced38780..c98a75aa 100644 --- a/README.md +++ b/README.md @@ -145,11 +145,7 @@ This directs puma to start the control server on localhost port 9293. Additional ### Configuration file -You can also provide a configuration file which puma will use: - - $ puma --config /path/to/config - -or +You can also provide a configuration file which puma will use with the `-C` (or `--config`) flag: $ puma -C /path/to/config From 54d811ca28f3f161bdea91b05a44f5ad2d2a712e Mon Sep 17 00:00:00 2001 From: Larry Marburger Date: Tue, 16 Jul 2013 16:02:25 -0400 Subject: [PATCH 3/5] Grammar tweak --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index c98a75aa..df8763d8 100644 --- a/README.md +++ b/README.md @@ -153,7 +153,7 @@ Take the following [sample configuration](https://github.com/puma/puma/blob/mast ## Restart -Puma includes the ability to restart itself, allowing for new versions to be easily upgraded to. When available (MRI, Rubinius, JRuby), puma performs a "hot restart". This is the same functionality available in *unicorn* and *nginx* which keep the server sockets open between restarts. This makes sure that no pending requests are dropped while the restart is taking place. +Puma includes the ability to restart itself allowing easy upgrades to new versions. When available (MRI, Rubinius, JRuby), puma performs a "hot restart". This is the same functionality available in *unicorn* and *nginx* which keep the server sockets open between restarts. This makes sure that no pending requests are dropped while the restart is taking place. To perform a restart, there are 2 builtin mechanisms: From 230f77b09f862b76173ffd45b2469e088c95750a Mon Sep 17 00:00:00 2001 From: Larry Marburger Date: Tue, 16 Jul 2013 16:02:37 -0400 Subject: [PATCH 4/5] Fix typo --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index df8763d8..c93cdcf1 100644 --- a/README.md +++ b/README.md @@ -166,7 +166,7 @@ If the new process is unable to load, it will simply exit. You should therefore ### Cleanup Code -Puma isn't able to understand all the resources that your app may use, so it provides a hook in the configuration file you pass to `-C` call `on_restart`. The block passed to `on_restart` will be called, unsurprisingly, just before puma restarts itself. +Puma isn't able to understand all the resources that your app may use, so it provides a hook in the configuration file you pass to `-C` called `on_restart`. The block passed to `on_restart` will be called, unsurprisingly, just before puma restarts itself. You should place code to close global log files, redis connections, etc in this block so that their file descriptors don't leak into the restarted process. Failure to do so will result in slowly running out of descriptors and eventually obscure crashes as the server is restart many times. From 862c2c11407f1f2bcf54c0fdf24f59cbc7d712ae Mon Sep 17 00:00:00 2001 From: Larry Marburger Date: Tue, 16 Jul 2013 16:03:18 -0400 Subject: [PATCH 5/5] Mark CLI commands --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index c93cdcf1..8af73dd3 100644 --- a/README.md +++ b/README.md @@ -190,7 +190,7 @@ or will cause the server to perform a restart. `pumactl` is a simple CLI frontend to the control/status app described above. -Allowed commands: status, restart, halt, stop +Allowed commands: `status`, `restart`, `halt`, `stop` ## Managing multiple Pumas / init.d / upstart scripts