Pkg: Proxy issue

Created on 12 May 2017  路  7Comments  路  Source: vercel/pkg

At work i'm dehind a proxy and i got the folowing error message :

> Fetching base Node.js binaries to: ~/.pkg-cache
  fetched-v7.6.0-win-x64       [====================] 100%
> Error! connect ETIMEDOUT 192.30.253.113:443
> Asset 'v1.9/uploaded-v1.9-node-v7.6.0-win-x64' not found by direct link
> Error! connect ETIMEDOUT 192.30.253.117:443

do i have to configure something ?
I already configure npm to go through my proxy.

Most helpful comment

Ugly solution :
got to https://github.com/zeit/pkg-fetch/releases/tag/v1.9
Download the versions you want
go to your ./pkg-cache folder (for me win computer : C:\Users\{userid}\.pkg-cache\v1.9)
copy the bin downloaded before
change the start of the file to be starting by fetched and not uploaded
remove file with '.downloading'
try again it should work

All 7 comments

Ugly solution :
got to https://github.com/zeit/pkg-fetch/releases/tag/v1.9
Download the versions you want
go to your ./pkg-cache folder (for me win computer : C:\Users\{userid}\.pkg-cache\v1.9)
copy the bin downloaded before
change the start of the file to be starting by fetched and not uploaded
remove file with '.downloading'
try again it should work

馃憤

This solution should be part of the docs. See #243

Note also that as of now just replacing uploaded with fetched doesn't work - you'll want to have the failure first so there's that .downloading file and rename it to what the .downloading file had, then just remove .downloading

This is old but still, it might be useful to some :

PKG uses the module PKG-FETCH to download required bin files.
PKG-FETCH uses REQUEST module to query github. REQUEST uses by default your HTTPS_PROXY and HTTP_PROXY environment variables to send request.
So just set this or these var and you'll be good to go.

If you still have an error like "Failed to get local issuer certificate" then your you can try to set NODE_TLS_REJECT_UNAUTHORIZED=0

Facing same error , can you help

Targets not specified. Assuming:
node10-linux-x64, node10-macos-x64, node10-win-x64
Fetching base Node.js binaries to PKG_CACHE_PATH
fetched-v10.15.3-win-x64 [ ] 0%
Error! getaddrinfo EAI_AGAIN github.com github.com:443
Asset not found by direct link:
{"tag":"v2.6","name":"uploaded-v2.6-node-v10.15.3-win-x64"}
Error! getaddrinfo EAI_AGAIN api.github.com api.github.com:443

Try these steps https://docs.cloudfoundry.org/cf-cli/http-proxy.html
And most importantly, restart your machine and try the pkg . command again.
It definitely works!

Was this page helpful?
0 / 5 - 0 ratings