]> ruin.nu Git - ndwebbie.git/blob - lib/NDWeb.pm
Converted forum to catalyst.
[ndwebbie.git] / lib / NDWeb.pm
1 package NDWeb;
2
3 use strict;
4 use warnings;
5
6 use Catalyst::Runtime '5.70';
7
8 #Need to preload, otherwise the first hit is slow
9 use CGI qw/:standard/;
10 escapeHTML('');
11
12 # Set flags and add plugins for the application
13 #
14 #         -Debug: activates the debug mode for very useful log messages
15 #   ConfigLoader: will load the configuration from a YAML file in the
16 #                 application's home directory
17 # Static::Simple: will serve static files from the application's root 
18 #                 directory
19
20 use parent qw/Catalyst/;
21
22 our $VERSION = '0.01';
23
24 # Configure the application. 
25 #
26 # Note that settings in ndweb.yml (or other external
27 # configuration file that you set up manually) take precedence
28 # over this when using ConfigLoader. Thus configuration
29 # details given here can function as a default configuration,
30 # with a external configuration file acting as an override for
31 # local deployment.
32
33 __PACKAGE__->config( name => 'NDWeb' );
34 __PACKAGE__->config->{'Plugin::Authentication'}{'use_session'} = 1;
35
36
37
38 # Start the application
39 __PACKAGE__->setup(qw/
40         -Debug
41         ConfigLoader
42         Static::Simple
43
44         Authentication
45         Authentication::Store::NDWeb
46         Authentication::Credential::Password
47
48         Authorization::Roles
49         Authorization::ACL
50         
51         Session
52         Session::Store::File
53         Session::State::Cookie
54         /);
55
56 =head1 NAME
57
58 NDWeb - Catalyst based application
59
60 =head1 SYNOPSIS
61
62     script/ndweb_server.pl
63
64 =head1 DESCRIPTION
65
66 [enter your description here]
67
68 =head1 SEE ALSO
69
70 L<NDWeb::Controller::Root>, L<Catalyst>
71
72 =head1 AUTHOR
73
74 Catalyst developer
75
76 =head1 LICENSE
77
78 This library is free software, you can redistribute it and/or modify
79 it under the same terms as Perl itself.
80
81 =cut
82
83 1;