spookaw has asked for the wisdom of the Perl Monks concerning the following question:

Need to install CPAN Modules on Win7 computers not connected to the internet. I have a couple of ideas to research, but thought I would check here and see if there is a way to do it. I have the .pm files of the modules I need installed. Using Strawberry Perl too!

Replies are listed 'Best First'.
Re: CPAN module non-internet install
by marto (Cardinal) on Sep 15, 2018 at 15:15 UTC

    Here is how i achieve this at work. On a system which has internet access use minicpan to create mirror, transfer the files to your system that doesn't have internet access. Configure cpan/cpanm to point to this mirror. Install modules as usual. Of course you can just put this behind a web server to make it easier for multiple clients to use the same mirror.

    Update: added last sentence.

      Thanks I will try this and see if it works for me in my situation at work.

        Check out the documentation, it explains how to limit what you download. Without any filtering it's ~10GB.

Re: CPAN module non-internet install
by fishy (Friar) on Sep 15, 2018 at 18:38 UTC
Re: CPAN module non-internet install
by Anonymous Monk on Sep 17, 2018 at 22:56 UTC
    Don't use the .pm files directly. Make a cpanfile of your requirements then you can use Carton to create an offline bundle for installation, which can be installed directly by cpanm on the target system as long as you used a recent Carton. carton install; carton bundle then copy the vendor/cache directory to the target and see https://metacpan.org/pod/Carton#Bundling-modules.