If you are using nvm behide a proxy you need set proxy config to curl
edit or create the file ~/.curlrc and add this line with your proxy
echo 'proxy=http://<proxy-user>:<proxy-pass>@<proxy-url>:<proxy-port>' >> ~/.curlrc
if your proxy does not need a user and password, you can use it:
echo 'proxy=http:<proxy-url>:<proxy-port>' >> ~/.curlrc