fix version in pod
[gitmo/MooseX-Daemonize.git] / lib / MooseX / Daemonize.pm
index d0c60c6..4cb6cb3 100644 (file)
@@ -4,7 +4,7 @@ use Moose::Role;
 use MooseX::Types::Path::Class;
 use File::Path qw(make_path);
 
-our $VERSION   = '0.15';
+our $VERSION   = '0.16';
 
 with 'MooseX::Daemonize::WithPidFile',
      'MooseX::Getopt';
@@ -22,6 +22,7 @@ has progname => (
         ( my $name = lc $_[0]->meta->name ) =~ s/::/_/g;
         return $name;
     },
+    documentation => 'the name of the daemon',
 );
 
 has pidbase => (
@@ -32,6 +33,7 @@ has pidbase => (
     required  => 1,
     lazy      => 1,
     default   => sub { Path::Class::Dir->new('', 'var', 'run') },
+    documentation => 'the base for our pid (default: /var/run)',
 );
 
 has basedir => (
@@ -42,6 +44,7 @@ has basedir => (
     required  => 1,
     lazy      => 1,
     default   => sub { Path::Class::Dir->new('/') },
+    documentation => 'the directory to chdir to (default: /)',
 );
 
 has foreground => (
@@ -50,13 +53,15 @@ has foreground => (
     isa         => 'Bool',
     is          => 'ro',
     default     => sub { 0 },
+    documentation => 'if true, the process won\'t background',
 );
 
 has stop_timeout => (
     metaclass => 'Getopt',
     isa       => 'Int',
     is        => 'rw',
-    default   => sub { 2 }
+    default   => sub { 2 },
+    documentation => 'number of seconds to wait for the process to stop, before trying harder to kill it (default: 2 s)',
 );
 
 # internal book-keeping
@@ -312,10 +317,6 @@ __END__
 
 MooseX::Daemonize - Role for daemonizing your Moose based application
 
-=head1 VERSION
-
-This document describes MooseX::Daemonize version 0.15
-
 =head1 WARNING
 
 The maintainers of this module now recommend using L<Daemon::Control> instead.
@@ -395,6 +396,10 @@ The name of our daemon, defaults to C<$package_name =~ s/::/_/>;
 
 The base for our PID, defaults to C</var/run/>
 
+=item I<basedir Path::Class::Dir | Str>
+
+The directory we chdir to; defaults to C</>.
+
 =item I<pidfile MooseX::Daemonize::Pid::File | Str>
 
 The file we store our PID in, defaults to C<$pidbase/$progname.pid>