Env::Heroku - set Heroku add-on specific environment variables
version 0.003
## app.psgi use Env::Heroku::Pg; use Env::Heroku::Redis; ## catalyst app config 'Model::DB' => { schema_class => 'WebApp::Schema', connect_info => [ 'dbi:Pg:', undef, undef, { pg_enable_utf8 => 1, auto_savepoint => 1, } ], }
Set Heroku add-on specific environment variables from Heroku config environment variables to the respective default variables.
For example Env::Heroku::Pg will unpack the DATABASE_URL env postgres://user:password@hostname:port/database to env variables PGUSER, PGPASSWORD, PGHOST, PGPORT and PGDATABASE and respective DBI_* variables.
Env::Heroku::Pg
postgres://user:password@hostname:port/database
This allows site configuration to NOT specify database connection info in configuration files that are under version control, but use the Heroku env/config pattern to manage such attached resources.
http://12factor.net/
Panu Ervamaa <pnu@cpan.org>
This software is copyright (c) 2015 by Panu Ervamaa.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Env::Heroku, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Env::Heroku
CPAN shell
perl -MCPAN -e shell install Env::Heroku
For more information on module installation, please visit the detailed CPAN module installation guide.