Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Installing luarocks package for torch behind proxy

I am looking to use the nn package for the torch framework. I downloaded and built torch from github. But when I now do :

    luarocks install nn

I get Cloning into 'nn' fatal: unable to connect to github.com error. My proxy servers are configured for wget and github. Both are working fine. I looked online and could only find this, so I looked for config.lua but there were many so I added to all this:

    proxy="proxy@port"

But luarocks still does not work. Please suggest something.

like image 539
Jagadeesh Avatar asked Jan 08 '23 14:01

Jagadeesh


1 Answers

I have found a solution. The proxy blocks git:// urls, so instead using https:// fixes the issue. The command is:
git config --global url.https://github.com/.insteadOf git://github.com/

The url can also be modified in the git.lua file if one does not wish to change global git settings

like image 182
Jagadeesh Avatar answered Feb 15 '23 12:02

Jagadeesh