eirslett / frontend-maven-plugin

"Maven-node-grunt-gulp-npm-node-plugin to end all maven-node-grunt-gulp-npm-plugins." A Maven plugin that downloads/installs Node and NPM locally, runs NPM install, Grunt, Gulp and/or Karma.
Apache License 2.0
4.2k stars 868 forks source link

Proxy Error on multiple Proxies #238

Open sja opened 9 years ago

sja commented 9 years ago

fronten-maven-plugin just handles one Proxy. But if I have two proxy URLs for http and https it fails with the messages I attached below. In that case, the first proxy is used which can be the wrong one. I worked around by switching the proxy order in my settings.xml and the the first was the right proxy.

After node is installed, the npm install fails again, because --proxy=... is added. Https-Proxy param is missing.

Solution would be to check the Node/NPM download url protocol to select the right proxy.

[INFO] --- frontend-maven-plugin:0.0.23:install-node-and-npm (Install node and npm) @ org.openhab.xxx ---
[INFO] Installing node version v0.12.3
[INFO] Creating temporary directory /var/lib/jenkins/jobs/openhab2/workspace/addons/ui/org.openhab.xxx/node_tmp
[INFO] Downloading Node.js from http://nodejs.org/dist/v0.12.3/node-v0.12.3-linux-x64.tar.gz to /var/lib/jenkins/jobs/openhab2/workspace/addons/ui/org.openhab.xxx/node_tmp/node.tar.gz
[INFO] Downloading via proxy ProxyConfig{protocol='https', host='proxy.intern.xxx.de', port=8080}

...

[ERROR] Failed to execute goal com.github.eirslett:frontend-maven-plugin:0.0.23:install-node-and-npm (Install node and npm) on project org.openhab.xxx: Could not download Node.js: Could not download http://nodejs.org/dist/v0.12.3/node-v0.12.3-linux-x64.tar.gz: Unrecognized SSL message, plaintext connection? -> [Help 1]
jdamick commented 8 years ago

Also seeing this issue..