Pinto icon indicating copy to clipboard operation
Pinto copied to clipboard

"Couldn't find module or a distribution Pinto"

Open lsiden opened this issue 6 years ago • 6 comments

When I attempt to run the install script downloaded from http://getpinto.stratopan.com it fails with the message "Couldn't find module or a distribution Pinto".

Steps:

  • curl -L http://getpinto.stratopan.com >install_pinto.sh
  • I edited install_into.sh so that "curl --quiet" becomes "curl -k" (ignore certificate).
  • bash -x install_pinto.sh

Output is

set -ue
+ PINTO_REPO_URL=https://www.stratopan.com/thaljef/OpenSource/pinto-release
+ PINTO_HOME=/var/pinto
+ '[' -z ']'
+ type curl
+ PINTO_INSTALLER_AGENT=curl
+ PINTO_CPANM_URL=https://raw.githubusercontent.com/thaljef/Pinto/master/etc/cpanm
+ PINTO_SBIN=/var/pinto/sbin
+ PINTO_CPANM_EXE=/var/pinto/sbin/cpanm
+ mkdir -p /var/pinto/sbin
+ '[' curl = curl ']'
+ curl -k --show-error --location https://raw.githubusercontent.com/thaljef/Pinto/master/etc/cpanm
 % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                Dload  Upload   Total   Spent    Left  Speed
100  294k  100  294k    0     0   503k      0 --:--:-- --:--:-- --:--:--  502k
+ chmod 755 /var/pinto/sbin/cpanm
+ echo 'Installing pinto into /var/pinto'
Installing pinto into /var/pinto
+ export PERL_USE_UNSAFE_INC=1
+ PERL_USE_UNSAFE_INC=1
+ /var/pinto/sbin/cpanm --notest --quiet --mirror https://www.stratopan.com/thaljef/OpenSource/pinto-release --mirror-only --local-lib-contained /var/pinto --man-pages Pinto
! Couldn't find module or a distribution Pinto

I checked https://www.stratopan.com/thaljef/OpenSource/pinto-release and Pinto is indeed present.

I also tried to install Pinto directly from CPAN using Perl 5.28.0 and 5.26.1, but that fails in one of the tests (I believe in t/02-bowels/41-log.t).

Please advise which way you recommend that I proceed.

lsiden avatar Jan 21 '19 22:01 lsiden

Got a bit more info to work with. I edited the script again, removed "--quiet" and added "-v" to the cpanm command in the script and got

ERROR: cannot verify www.stratopan.com's certificate, issued by ‘/C=GB/ST=Greater Manchester/L=Salford/O=COMODO CA Limited/CN=COMODO RSA Domain Validation Secure Server CA’:
  Issued certificate has expired.
To connect to www.stratopan.com insecurely, use `--no-check-certificate'.

However, when I added --no-check-certificate, I still get the same result.

Still stumped.

lsiden avatar Jan 21 '19 22:01 lsiden

You're running into the same issue as #246. Still no word back from Jeffery on this, unfortunately. :-(

barefootcoder avatar Jan 25 '19 22:01 barefootcoder

cpanm calls curl internally. You can create a ~/.curlrc file that contains -k and things should work. E.g.

# HEADS UP, DON'T DO THIS IS YOU HAVE IMPORTANT THINGS IN ~/.curlrc;
# append, or use vi, or ...
(alice)[15:04:46]~>>echo "-k" > ~/.curlrc

If you can't do that for some reason, but have access to wget, you can use it's configuration file (man wget) to pull the same trick.

hartzell avatar Jan 25 '19 23:01 hartzell

p.s.: REMOVE THIS OPTION WHEN YOU'RE DONE, otherwise you're disabling validation for everything.

hartzell avatar Jan 25 '19 23:01 hartzell

FWIW, if you're on a system where cpanm chooses to use wget instead of curl, you can achieve the same end be creating a ~/.wgetrc that contains (at least):

check-certificate=off

Same caveat about cleaning up after you're done.

hartzell avatar Feb 15 '19 22:02 hartzell

The ~/.curlrc and ~/.wgetrc suggestions to disable certificate checking did not work for me.

Does anybody else have viable workaround?

tomwitt2 avatar Mar 18 '19 15:03 tomwitt2