FCGI::...Manager(3pm)
π FCGI::Engine::Manager π
okay so bestie, welcome to the FCGI::Engine::Manager page β it's a Perl module (from the User Contributed Perl Documentation, iykyk) and it's literally here to manage multiple FCGI::Engine instances for you. slay. let's get into it β¨
β¨ NAME β¨
FCGI::Engine::Manager β manage multiple FCGI::Engine instances π
πΈ SYNOPSIS πΈ
here's the vibe, bestie:
#!/usr/bin/perl
my $m = FCGI::Engine::Manager->new(
conf => 'conf/my_app_conf.yml'
);
my ($command, $server_name) = @ARGV;
$m->start($server_name) if $command eq 'start';
$m->stop($server_name) if $command eq 'stop';
$m->restart($server_name) if $command eq 'restart';
$m->graceful($server_name) if $command eq 'graceful';
print $m->status($server_name) if $command eq 'status';
# on the command line
perl all_my_fcgi_backends.pl start
perl all_my_fcgi_backends.pl stop
perl all_my_fcgi_backends.pl restart foo.server
# etc ...
π¦ DESCRIPTION π¦
so this module handles multiple FCGI::Engine instances for you β it can start, stop, and give you basic status info. it's configurable using Config::Any, but ngl, only really the YAML format has actually been tested. π
π Use with Catalyst
since FCGI::Engine is pretty much compatible with Catalyst::Engine::FastCGI, this module can also be used to manage your Catalyst::Engine::FastCGI based apps as well as your FCGI::Engine based apps. main character energy fr fr π
π§ Use with Plack
Plack support is provided via the FCGI::Engine::Manager::Server::Plackup module. all that's required is setting the "server_class" parameter in the configuarion and it will Just Work. β¨
π EXAMPLE CONFIGURATION π
here's an example configuration in YAML, bestie. it should be noted that the options for each server are basically the constructor params to FCGI::Engine::Manager::Server and are passed verbatim to it. this means that if you subclass FCGI::Engine::Manager::Server and set the "server_class:" option appropriately, it should pass any new options you added to your subclass automatically. the third server in the list shows exactly how this is used with a Plack application. π
---
- name: "foo.server"
server_class: "FCGI::Engine::Manager::Server"
scriptname: "t/scripts/foo.pl"
nproc: 1
pidfile: "/tmp/foo.pid"
socket: "/tmp/foo.socket"
additional_args: [ "-I", "lib/" ]
- name: "bar.server"
scriptname: "t/scripts/bar.pl"
nproc: 1
pidfile: "/tmp/bar.pid"
socket: "/tmp/bar.socket"
- name: "baz.server"
server_class: "FCGI::Engine::Manager::Server::Plackup"
scriptname: "t/scripts/baz.psgi" # the .psgi file
nproc: 1
pidfile: "/tmp/baz.pid"
socket: "/tmp/baz.socket"
additional_args: [ "-E", "production" ] # plackup specific option
π BUGS π
all complex software has bugs lurking in it, and this module is no exception. if you find a bug please either email me, or add the bug to cpan-RT. π«Ά
π AUTHOR π
Stevan Little <stevan@iinteractive.com>
π COPYRIGHT AND LICENSE π
Copyright 2007-2010 by Infinity Interactive, Inc.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
and that's the whole page, bestie π this was perl v5.36.0, dated 2022-12-10, from the FCGI::...Manager(3pm) manual β go forth and manage those backends, you absolute icon πβ¨π¦
π¦ where this page comes from
- debian bookworm: libfcgi-engine-perl 0.22-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- debian trixie: libfcgi-engine-perl 0.22-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libfcgi-engine-perl 0.22-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libfcgi-engine-perl 0.22-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libfcgi-engine-perl 0.22-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms