Plack::Middleware::ServerStatus::Lite - show server status like Apache's mod_status
use Plack::Builder; builder { enable "Plack::Middleware::ServerStatus::Lite", path => '/server-status', allow => [ '127.0.0.1', '192.168.0.0/16' ], scoreboard => '/var/run/server'; $app; }; % curl http://server:port/server-status Uptime: 1234567789 BusyWorkers: 2 IdleWorkers: 3 -- pid status remote_addr host method uri protocol 20060 A 127.0.0.1 localhost:10001 GET / HTTP/1.1 20061 . 20062 A 127.0.0.1 localhost:10001 GET /server-status HTTP/1.1 20063 . 20064 .
Plack::Middleware::ServerStatus::Lite is a middleware that display server status in multiprocess Plack servers such as Starman and Starlet. This middleware changes status only before and after executing the application. so cannot monitor keepalive session and network i/o wait.
path => '/server-status',
location that displays server status
allow => '127.0.0.1' allow => ['192.168.0.0/16', '10.0.0.0/8']
host based access control of a page of server status
scoreboard => '/path/to/dir'
Scoreboard directory, Middleware::ServerStatus::Lite stores processes activity information in
Masahiro Nagano <kazeburo {at} gmail.com>
Original ServerStatus by cho45 <http://github.com/cho45/Plack-Middleware-ServerStatus>
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install Plack::Middleware::ServerStatus::Lite, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Plack::Middleware::ServerStatus::Lite
CPAN shell
perl -MCPAN -e shell install Plack::Middleware::ServerStatus::Lite
For more information on module installation, please visit the detailed CPAN module installation guide.