Version 5.90006
[catagits/Catalyst-Runtime.git] / lib / Catalyst / Script / FastCGI.pm
index 1b2a2e9..ba6ab9b 100644 (file)
@@ -90,8 +90,9 @@ sub _plack_loader_args {
     my ($self) = shift;
 
     my $opts = Data::OptList::mkopt([
-      qw/pidfile manager nproc proc_title/,
-            detach          => [ 'daemon' ],
+      qw/manager nproc proc_title/,
+            pid             => [ 'pidfile' ],
+            daemonize       => [ 'daemon' ],
             keep_stderr     => [ 'keeperr' ],
             listen          => [ '_listen' ],
         ]);
@@ -104,11 +105,12 @@ sub _plack_loader_args {
     return %args;
 }
 
-sub _application_args {
-    my ($self) = shift;
+around _application_args => sub {
+    my ($orig, $self) = @_;
     return (
         $self->listen,
         {
+            %{ $self->$orig },
             nproc       => $self->nproc,
             pidfile     => $self->pidfile,
             manager     => $self->manager,
@@ -117,9 +119,10 @@ sub _application_args {
             proc_title  => $self->proc_title,
         }
     );
-}
+};
 
 __PACKAGE__->meta->make_immutable;
+1;
 
 =head1 NAME
 
@@ -152,6 +155,10 @@ Catalyst::Script::FastCGI - The FastCGI Catalyst Script
 
 Run a Catalyst application as fastcgi.
 
+=head1 SEE ALSO
+
+L<Catalyst::ScriptRunner>
+
 =head1 AUTHORS
 
 Catalyst Contributors, see Catalyst.pm