cypress install no_proxy not working ?
pagadalacs opened this issue · comments
Current behavior:
node:11.7.0
npm:6.5.0
cross-env: 7.0.2
my package.json file :
"scripts": {
...
"preinstall": "npm install --no-package-lock cross-env run-script-os rxjs && npm run install:cypress",
"install:cypress:linux": "cross-env CYPRESS_INSTALL_BINARY=https://internal.nexus.repo/cypress/4.0.2/cypress-4.0.2-linux-x64.zip npm install cypress@4.0.2 --save-exact",
...
},
npm install always trying to use http_proxy it seems, and apparently it fails, since its our internal repo doesn't need proxy. i added in no_proxy=.nexus.repo environment variable to bypass proxy. I have proxy and no_proxy configured in environment variables and also in .npmrc also. Looks like no_proxy option not working in this case ? Any help us appreciated ?
Desired behavior:
cypress install should ignore proxy
output on jenkins :
npm info lifecycle cypress@4.0.2~postinstall: cypress@4.0.2
cypress@4.0.2 postinstall /opt/jenkins/workspace/npm_testjob/node_modules/cypress
node index.js --exec install
The CLI expected to install version: 4.0.2
Instead we will install version: https://internal.nexus.repo/cypress/4.0.2/cypress-4.0.2-linux-x64.zip
These versions may not work properly together.
Installing Cypress (version: https://internal.nexus.repo/cypress/4.0.2/cypress-4.0.2-linux-x64.zip )
�[?25l[06:10:04] Downloading Cypress [started]
[06:10:04] Downloading Cypress [failed]
�[?25hThe Cypress App could not be downloaded.
Does your workplace require a proxy to be used to access the Internet? If so, you must configure the HTTP_PROXY environment variable before downloading Cypress. Read more: https://on.cypress.io/proxy-configuration
Otherwise, please check network connectivity and try again:
I solved the issue, its workaround : configured cntlm proxy , that able to bypass proxies for all the internal repos or all domains menioned in "noProxy" . just in case somebody is struggling with same issue as above.
so in env :
export http_proxy = http:/10.0.0.10:3128 ( cntlm proxy)
in cntlm proxy :
Proxy http://corporateproxy
NoProxy localhost, 127.0.0.*, .nexus.repo