Default to sending X-Catalyst header
[catagits/Catalyst-Devel.git] / share / lib / MyApp.pm.tt
CommitLineData
239b5fc0 1package [% name %];
8662edf6 2use Moose;
3use namespace::autoclean;
239b5fc0 4
5use Catalyst::Runtime 5.80;
6
e1893b6a 7# Set flags and add plugins for the application.
8#
9# Note that ORDERING IS IMPORTANT here as plugins are initialized in order,
10# therefore you almost certainly want to keep ConfigLoader at the head of the
11# list if you're using it.
239b5fc0 12#
13# -Debug: activates the debug mode for very useful log messages
14# ConfigLoader: will load the configuration from a Config::General file in the
15# application's home directory
16# Static::Simple: will serve static files from the application's root
17# directory
18
0c34c8b8 19use Catalyst qw/
7e6d9ba3 20 -Debug
0c34c8b8 21 ConfigLoader
22 Static::Simple
23/;
8662edf6 24
25extends 'Catalyst';
26
239b5fc0 27our $VERSION = '0.01';
28
29# Configure the application.
30#
31# Note that settings in [% appprefix %].conf (or other external
32# configuration file that you set up manually) take precedence
33# over this when using ConfigLoader. Thus configuration
34# details given here can function as a default configuration,
35# with an external configuration file acting as an override for
36# local deployment.
37
0c34c8b8 38__PACKAGE__->config(
7e6d9ba3 39 name => '[% name %]',
40 # Disable deprecated behavior needed by old applications
41 disable_component_resolution_regex_fallback => 1,
51b186e7 42 enable_catalyst_header => 1, # Send X-Catalyst header
0c34c8b8 43);
239b5fc0 44
45# Start the application
46__PACKAGE__->setup();
47
48
49=head1 NAME
50
51[% name %] - Catalyst based application
52
53=head1 SYNOPSIS
54
55 script/[% appprefix %]_server.pl
56
57=head1 DESCRIPTION
58
59[enter your description here]
60
61=head1 SEE ALSO
62
63L<[% rootname %]>, L<Catalyst>
64
65=head1 AUTHOR
66
67[% author %]
68
69=head1 LICENSE
70
71This library is free software. You can redistribute it and/or modify
72it under the same terms as Perl itself.
73
74=cut
75
761;