[DEPRECATED]
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib/Mojolicious/Plugin
t
xt
.gitignore
Changes
MANIFEST
MANIFEST.SKIP
Makefile.PL
README.pod

README.pod

NAME

Mojolicious::Plugin::UnmessifyBundle -

SYNOPSIS

sub startup {
    
    my $self = shift;
    
    # Mojolicious
    $self->plugin(unmessify_bundle => {prefix => 'mojolicious-bundle'});
    
    # Mojolicious::Lite
    plugin unmessify_bundle => {prefix => 'mojolicious-bundle'};
}

# mod_rewrite can be as follows.

RewriteEngine on
RewriteRule ^(.*(\.(html|htm|xml))|/)$ http://localhost:3000$1 [L,P,QSA]
RewriteRule ^/mojolicious-bundle(/.+)$ http://localhost:3000$1 [L,P,QSA]

DESCRIPTION

Deploying mojolicious behind white listed reverse proxy causes bundle files inaccessible unless each of them is listed. This plugin modifies the paths as if the files are in a single directory so that the white list can be a one-liner.

METHODS

register

$plugin->register;

Register plugin hooks in Mojolicious application.

AUTHOR

Sugama Keita, <sugama@jamadam.com>

COPYRIGHT AND LICENSE

Copyright (C) 2011 by Sugama Keita.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.