CPAN install from a local directory

M

Matt C

Hi All,

is it possible to have the CPAN util install packages from a local
dir, rather than a mirror?

I need to install an application on a load of client machines that
needs quite a few perl modules to do its thing. I'd like to download
all the perl modules as tar.gz files and then put them on an install
cd with the other parts of the app. I will script up a basic
installer that will, amoungst other things, install the perl mods onto
the target machine.

Can I get CPAN to do this for me? Can I call it, tell it to install
and point it at the dir full of tar and gzipped perl mods?

Is there a better way to do this?

cheers in advance

matt
 
A

Anno Siegel

Matt C said:
Hi All,

is it possible to have the CPAN util install packages from a local
dir, rather than a mirror?

I need to install an application on a load of client machines that
needs quite a few perl modules to do its thing. I'd like to download
all the perl modules as tar.gz files and then put them on an install
cd with the other parts of the app. I will script up a basic
installer that will, amoungst other things, install the perl mods onto
the target machine.

You can use a local mirror. Place a "file" URL that points to the
mirror in the urllist of your CPAN configuration.

Also consider building a bundle of the modules you want to install.
Can I get CPAN to do this for me? Can I call it, tell it to install
and point it at the dir full of tar and gzipped perl mods?

Yes, as described in the CPAN doc.

Anno
 
B

Brian McCauley

is it possible to have the CPAN util install packages from a local
dir, rather than a mirror?

You can put local directories to the list of repositories that CPAN.pm is
to use. For details RTFM.
I need to install an application on a load of client machines that
needs quite a few perl modules to do its thing. I'd like to download
all the perl modules as tar.gz files and then put them on an install
cd with the other parts of the app. I will script up a basic
installer that will, amoungst other things, install the perl mods onto
the target machine.

Can I get CPAN to do this for me? Can I call it, tell it to install
and point it at the dir full of tar and gzipped perl mods?

You can create a "bundle" module that is nothing but a list of
dependancies and install that.

--
\\ ( )
. _\\__[oo
.__/ \\ /\@
. l___\\
# ll l\\
###LL LL\\
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top