generator-office icon indicating copy to clipboard operation
generator-office copied to clipboard

Running thru a proxy/corp environment

Open lrauhockey opened this issue 2 years ago • 1 comments

Prerequisites

Please answer the following questions before submitting an issue. YOU MAY DELETE THE PREREQUISITES SECTION.

  • [X ] I am running the latest version of Node and the tools
  • [ X] I checked the documentation and found no answer
  • [ X] I checked to make sure that this issue has not already been filed

Expected behavior

Please describe the behavior you were expecting In running yo office i am expecting it to create the directories/files needed. Any option can be selected

Current behavior

I am getting errors. Error: connect ETIMEDOUT 20.42.73.142:443 at TCPConnectWrap.afterConnect [as oncomplete] node:net:1300:16] at TCPConnectWrap.callbackTramoline (node:internal/async_hooks:130:17)

it appears that i cannot get thru the proxy and was asked is there is a way to setup a cdnulr properties to add to npmrc

Please provide information about the failure. What is the current behavior? If it is not a bug, please add it to UserVoice, so that it gets added to our feature roadmap.

Steps to Reproduce

Please provide detailed steps for reproducing the issue.

  1. npm install -g yo
  2. npm install -g yo generator office
  3. yo office

Context

Please provide any relevant information about your setup. This is important in case the issue is not reproducible except for under certain conditions.

  • Operating System: Linux
  • Node version: Latest version (and tried older version like 18.12.1 also)
  • Office version: O365
  • Tool version: 1.9.7

Failure Logs

Please include any relevant log snippets, screenshots or code samples here.

lrauhockey avatar Dec 15 '23 13:12 lrauhockey

Are you still seeing those errors or have you been able to resolve this?

Oleg-O avatar Oct 19 '24 23:10 Oleg-O

I have the same/similar issue, client machine is connected via ZScaler Proxy, I created a ".npmrc" file with "proxy", "http-proxy" and "https-proxy" values pointing to the proxy, I used "scrict-ssl=false". NPM is working fine now but "yo office" is failing with:

Unable to download project zip file for "https://github.com/OfficeDev/Office-Addin-TaskPane-React/archive/yo-office.zip". Error: getaddrinfo ENOTFOUND github.com

pruembeli avatar Oct 30 '24 16:10 pruembeli

Are you able to browse https://github.com/OfficeDev/Office-Addin-TaskPane-React in your web browser? The generator-office gets template content from github.com and needs to have access to that side from behind any kind of firewall or proxy.

millerds avatar Oct 30 '24 21:10 millerds

Thanks for the reply, yes I can open the link in the browser because the browser is working with the proxy settings from windows, the page opens but the certificate for github.com was replaced by one from the proxy itself. NPM can be configured with creating a file ".npmrc" in c:\users\myName\ and it is using the proxy as well. How can I set the proxy for "yo office" or is it failing on the certificate?

pruembeli avatar Oct 31 '24 07:10 pruembeli

The generator-office plugin for yeoman uses a js library call "axois" to make the request to get the zip file. From what I can tell online, it honors the http_proxy, https_proxy, and no_proxy environment variables. I have not tried this myself, but it sounds like it should work.

millerds avatar Oct 31 '24 16:10 millerds

Sorry for the late reply.. But this is still not resolved. I wanted to try, but even though I can download the zip file directly thru a browser, it seems to be blocked.

On Wed, Oct 30, 2024 at 12:00 PM Philipp @.***> wrote:

I have the same/similar issue, client machine is connected via ZScaler Proxy, I created a ".npmrc" file with "proxy", "http-proxy" and "https-proxy" values pointing to the proxy, I used "scrict-ssl=false". NPM is working fine now but "yo office" is failing with:

Unable to download project zip file for " https://github.com/OfficeDev/Office-Addin-TaskPane-React/archive/yo-office.zip". Error: getaddrinfo ENOTFOUND github.com

— Reply to this email directly, view it on GitHub https://github.com/OfficeDev/generator-office/issues/799#issuecomment-2447637816, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGBUATDRLDMT4PBGQYOVNETZ6D7CDAVCNFSM6AAAAABQH5OWHCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDINBXGYZTOOBRGY . You are receiving this because you authored the thread.Message ID: @.***>

-- @.*** @.*** Larry Gold of course

lrauhockey avatar Nov 01 '24 12:11 lrauhockey

@lrauhockey, apologies for the delay here. Are you still seeing this issue?

kwame-ansong avatar Apr 30 '25 09:04 kwame-ansong