View on
MetaCPAN is shutting down
For details read Perl NOC. After June 25th this page will redirect to
Torsten Raudssus > Installer-0.904 > installto


Annotate this POD


View/Report Bugs


installto - Install an 'installer' configuration file


version 0.904


  # Will use installer file in current directory
  installto ~/myprojectenv

  # Using a specific installer file
  installto -f /other/installer_file ~/myprojectenv

  # The .installer file can also be fetched by URL:
  installto -u ~/myprojectenv

  # Giving installer code as string
  installto -e "perl '5.18.1'; cpanm 'Plack';" ~/myprojectenv

  # On shell do the following for using the environment after installation
  . ~/myprojectenv/

Sample .installer file might look like

  perl "5.18.1";
  url "", with => {
    pgport => 15432,
  url "";
  url "";
  url "";
  cpanm "DBD::Pg";



This software is made for taking away the annoying task of installing a common specific bundle of requirements to a target directory. In the target directory installto will generate a which can be used to get all the environment loaded to use the installed programs.

Bigger example for installer file options:

  url "http://host/file.tar.gz",
    with => {
      key => "value",
      other_key => undef,
    enable => [qw( satan )],
    disable => [qw( god )],
    without => [qw( religion )],
    testable => 1;

Would endup with the following parameter on ./configure: --with-key=value --with-other_key --enable-satan --disable-god --without-religion.

You can give HashRef or ArrayRef at enable, disable, with and without to achieve whatever configure setup you need.

Also it would run "make test" if there is a Makefile after configuration. Another options possible (so far):

  url "http://host/file.tar.gz",
    custom_test => sub {
    custom_configure => sub {
    post_install => sub {
      $self->run(undef,'command'); # run in target directory after install
    export_sh => sub {
      return "# extra lines", "# for getting added to", "#";

Same options can go towards a local file:

  file "/some/local/file.tar.gz";

You can also run a custom command (it will be run inside the target directory):

  run "custom_command", "args", "args";

Install specific perl (so far no options):

  perl "5.8.8";

Install specific postgresql (with all required step to have it all setup):

  postgres "9.3.0", port => 15432, superuser_with_db => 'myapp';

Or install packages via cpanm:

  cpanm qw( Yeb Dist::Zilla );

Be careful! It doesn't care if you have installed a perl in the target directory or not, and just fire up cpanm, so it would install on your local perl installation, if you didn't installed perl before.

Or install packages via pip:

  pip qw( rtree imposm );

Be careful! It doesn't care if you have installed pip in the target directory or not, and just fire up pip, so it would install on your local python environment, if you didn't installed pip before.


installto normally prints out the logfile of the output of the last procedure that fails. This allows easy fixing of those problems. You can then, after tuning the situation, restart the script and it retries the last comment (this might still a bit buggy, be warned).

In the case of a download problem or any other big problem that requires you to restart the specific step (like when you changed the URL to get a different version), you might want to delete fitting .json file in the installer directory, created in your target directory, this will force installto to redownload the file and restart this step complete over.


The generation of the still has some problem, you might need to adapt it by hand (for now).



  Join #cindustries on Highlight Getty for fast reaction :).

  Pull request and additional contributors are welcome

Issue Tracker


Torsten Raudssus <>


This software is copyright (c) 2013 by Torsten Raudssus.

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

syntax highlighting: