0

our Linux Systems have no Internet Access. Only Windows Clients have Internet Access. I want to build a offline CPAN Repository.

I can't download each Module an picking all the dependencies. Is there a way to download the Modules automated with dependencies to a Windows System? Even a whole download of the CPAN Repository would be a solution for me.

1 Answers1

3

You can create a local mirror of CPAN with minicpan. It's intended to distribute a copy of CPAN (or a subset of it) on media so you have it in case there is no internet available, e.g. a USB drive that you can use on a laptop while you are on an airplane so you can still install a dependency, even if it's outdated a bit.

Check out CPAN::Mini and the minicpan utility on CPAN as well as this guide on how to set up a mirror on perl.org. There is a guide on blogs.perl.org as well. Furthermore, this guide in German is very comprehensive and has a list of related material at the bottom.

In fact, there is a whole tag here on Stack Overflow. One of the very helpful reads (though not a full duplicate) is ysth's answer here.

Community
  • 1
  • 1
simbabque
  • 53,749
  • 8
  • 73
  • 136
  • I have decided not to quote any of the linked tutorials here as they are quite long. – simbabque Nov 24 '15 at 11:09
  • Hi simbabque, thank you for your reply. It looks a bit complex to create first an repository on windows were i first have to integrate perl in windows some more work and try and error. Is there no way to Download to whole repository? – user2273214 Nov 24 '15 at 13:24
  • How would you access it then? You can simply install an ActivePerl or a Strawberry Perl and use that. I've actually used CPAN::Mini to create 120 USB flash drives including the current latest full CPAN to give away at the German Perl Workshop as a sponsoring item for `$work`. It's super easy to make the minicpan (compared to creating an iso file and cloning that on 120 drives, that is). And getting the Perl on Windows is no problem. – simbabque Nov 24 '15 at 13:39
  • @user2273214 on the other hand, have you looked at Fatpacker to bundle all your deps with your program? – simbabque Nov 24 '15 at 13:40