Details
Description
Hi,
I've started porting Ambari 1.6.1(.1) on different environments (IBM PPC64, IBM JVM) and I have several issues.
One of them is, on RHEL 7 / PPC64, that Maven downloads x86_64 nodejs code (node v0.10.26 and npm 1.4.3) and tries to run it, though I already have nodejs available on my machine (/opt/node/bin/node , version v0.10.29).
Changing pom.xml files to version v0.10.29 for node did not fix the issue.
Following: https://cwiki.apache.org/confluence/display/AMBARI/Ambari+Development , I did :
mvn -B clean install package rpm:rpm -DnewVersion=${AMBARI_VERSION} -DskipTests -Dpython.ver="python > 2.6" -Preplaceurl
Traces are:
....
[INFO] Installing node version v0.10.26
[INFO] Creating temporary ....
[INFO] Downloading Node.js from http://nodejs.org/dist/v0.10.26/node-v0.10.26-linux-x64.tar.gz to ....}
[INFO] Extracting Node.js files in node_tmp
[INFO] Unpacking ... into /..../node_tmp
[INFO] Moving node binary to .../ambari/ambari-admin/src/main/resources/ui/admin-web/node/node
[INFO] Deleting temporary directory ...
[INFO] Installed node locally.
[INFO] Running 'npm install --unsafe-perm --color=false' in ...
[INFO] /home/reixt/AMBARI/FromAmbariGitHub/ambari/ambari-admin/src/main/resources/ui/admin-web/node/with_new_path.sh: ligne3: /home/reixt/AMBARI/FromAmbariGitHub/ambari/ambari-admin/src/main/resources/ui/admin-web/node/node : impossible to run binary file
$ file /home/reixt/AMBARI/FromAmbariGitHub/ambari/ambari-admin/src/main/resources/ui/admin-web/node/node
.../node: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.9, not stripped
This MVN/Ambari mechanism needs to be changed so that:
- it does not download nodejs (node, npm) code if node/npm commands are already available (with compatible versions) on my machine
- it uses compatible versions (as an example: use 0.10.29 if available on the machine already and version > 0.10.26 is required)
- it downloads node.js code for my machine architecture (arch awareness) if it is not available on the machine where I want to build Ambari.
For now, I found no work-around for this issue.