Preact-cli: preact create behind a corporate proxy

Created on 25 Oct 2017  Â·  2Comments  Â·  Source: preactjs/preact-cli


Do you want to request a feature or report a bug?
Bug

What is the current behavior?
I'm trying to use preact create default new-project behind a corporate proxy and it give me this:

ℹ INFO Assuming you meant preactjs-templates/default...
✖ ERROR connect ECONNREFUSED 192.30.253.113:443

What is the expected behavior?
It should create the app.

Please mention other relevant information.

  • node version : 8.4.0
  • npm version: 5.3.0
  • Operating system: Debian Stretch

It think that the problem comes from gittar, there is no way to configure the proxy to fetch the git template.

The only way to make it work is to use another connection without proxy.

stale

Most helpful comment

It might be worth us providing a way to specify a local template folder. @lukeed - think that'd be useful?

All 2 comments

@Dylanderv well, the v2 of preact-cli is using templates to generate the project structure so it is more flexible https://github.com/preactjs-templates therefore having no access to it will cause that issue.

Do you have no access to github from your corporate proxy ?

What you could do:

  • Go to the https://github.com/preactjs-templates/default page with your Browser, click on "Clone or download (green) button" -> Download Zip
  • Extract it on your project , or somewhere
  • Try to use a Reverse Proxy which returns the zip folder whenever github.com/preactjs-templates/default is requested

It might be worth us providing a way to specify a local template folder. @lukeed - think that'd be useful?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

nephix picture nephix  Â·  4Comments

c0debreaker picture c0debreaker  Â·  4Comments

jpoo90 picture jpoo90  Â·  4Comments

scottmas picture scottmas  Â·  3Comments

haggen picture haggen  Â·  3Comments