neutralinojs / neutralinojs-cli

neu cli for Neutralinojs
https://neutralino.js.org/docs/cli/neu-cli
MIT License
91 stars 57 forks source link

neu create fail behind a proxy #198

Open Fabien-B opened 1 year ago

Fabien-B commented 1 year ago

I am on Linux behind a proxy. I have the http_proxy and https_proxy environment variables set. I am using neu CLI: v9.4.0

$ neu create myApp

neu: INFO Downloading neutralinojs/neutralinojs-minimal template to myApp directory...
node:events:491
      throw er; // Unhandled 'error' event
      ^

Error: connect ECONNREFUSED 140.82.121.4:443
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1487:16)
Emitted 'error' event on Writable instance at:
    at eventHandlers.<computed> (/usr/local/lib/node_modules/@neutralinojs/neu/node_modules/follow-redirects/index.js:14:24)
    at ClientRequest.emit (node:events:513:28)
    at TLSSocket.socketErrorListener (node:_http_client:496:9)
    at TLSSocket.emit (node:events:513:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
  errno: -111,
  code: 'ECONNREFUSED',
  syscall: 'connect',
  address: '140.82.121.4',
  port: 443
}

Node.js v18.13.0

Are environment variables honored ? Is there a way to use neu create from behind a proxy?

Kanai2003 commented 6 months ago

@Fabien-B The error message ECONNREFUSED typically means that a TCP connection attempt was refused by the server you should try using sudo

Kanai2003 commented 6 months ago

@shalithasuranga please assign this issue to me my approach: add a support system for proxy setting to download