This file is indexed.

/usr/share/perl5/Poet/Server.pm is in libpoet-perl 0.16-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
package Poet::Server;
$Poet::Server::VERSION = '0.16';
use Poet qw($conf $poet);
use Method::Signatures::Simple;
use Class::Load;
use Class::MOP;
use strict;
use warnings;

method get_plackup_options () {

    my @options;

    # Pass -E with the layer name, e.g. "development" or "production"
    #
    push( @options, '-E', $conf->layer );

    if ( defined( my $port = $conf->get('server.port') ) ) {
        push( @options, '--port', $port );
    }
    if ( defined( my $host = $conf->get('server.host') ) ) {
        push( @options, '--host', $host );
    }

    if ( $conf->is_development ) {

        # In development mode, reload server when conf or lib file changes
        #
        push( @options, '-R', join( ",", $poet->conf_dir, $poet->lib_dir ) );
    }
    else {

        # In live mode, use access log instead of STDERR
        #
        push( @options, '--access-log', $poet->logs_path("access.log") );
    }

    return @options;
}

my $loaded_startup_modules;

method load_startup_modules () {
    return if $loaded_startup_modules++;
    foreach my $module ( @{ $conf->get_list('server.load_modules') } ) {
        Class::Load::load_class($module);
    }
}

1;