You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by vs...@apache.org on 2017/04/30 09:16:40 UTC

[07/13] ambari git commit: AMBARI-20885.Convert all Ambari Views to use yarn package manager(Venkata Sairam)

http://git-wip-us.apache.org/repos/asf/ambari/blob/21c3c7cd/contrib/views/hive20/pom.xml
----------------------------------------------------------------------
diff --git a/contrib/views/hive20/pom.xml b/contrib/views/hive20/pom.xml
index a583d23..a4ce74a 100644
--- a/contrib/views/hive20/pom.xml
+++ b/contrib/views/hive20/pom.xml
@@ -278,29 +278,35 @@
       <plugin>
         <groupId>com.github.eirslett</groupId>
         <artifactId>frontend-maven-plugin</artifactId>
-        <version>1.3</version>
+        <version>1.4</version>
         <configuration>
           <nodeVersion>v4.5.0</nodeVersion>
-          <npmVersion>2.15.0</npmVersion>
+          <yarnVersion>v0.23.2</yarnVersion>
           <workingDirectory>src/main/resources/ui/</workingDirectory>
           <npmInheritsProxyConfigFromMaven>false</npmInheritsProxyConfigFromMaven>
+          <!-- setting npm_config_tmp environment variable is a workaround for 
+               https://github.com/Medium/phantomjs/issues/673 -->
+          <environmentVariables>
+            <npm_config_tmp>/tmp/npm_config_tmp</npm_config_tmp>
+          </environmentVariables>
         </configuration>
         <executions>
           <execution>
-            <id>install node and npm</id>
+            <id>install node and yarn</id>
             <phase>generate-sources</phase>
             <goals>
-              <goal>install-node-and-npm</goal>
+              <goal>install-node-and-yarn</goal>
             </goals>
           </execution>
           <execution>
-            <id>npm install</id>
+            <id>yarn install</id>
             <phase>generate-sources</phase>
             <goals>
-              <goal>npm</goal>
+              <goal>yarn</goal>
             </goals>
             <configuration>
               <arguments>install --python="${project.basedir}/../src/main/unix/ambari-python-wrap" --unsafe-perm</arguments>
+              <arguments>--ignore-engines</arguments>
             </configuration>
           </execution>
         </executions>

http://git-wip-us.apache.org/repos/asf/ambari/blob/21c3c7cd/contrib/views/hive20/src/main/resources/ui/package.json
----------------------------------------------------------------------
diff --git a/contrib/views/hive20/src/main/resources/ui/package.json b/contrib/views/hive20/src/main/resources/ui/package.json
index 0453a52..a409111 100644
--- a/contrib/views/hive20/src/main/resources/ui/package.json
+++ b/contrib/views/hive20/src/main/resources/ui/package.json
@@ -11,7 +11,7 @@
     "build": "ember build",
     "start": "ember server",
     "test": "ember test",
-    "preinstall": "chmod +x node/node_modules/npm/bin/node-gyp-bin/node-gyp",
+    "preinstall": "",
     "postinstall": "node node_modules/.bin/bower --allow-root install"
   },
   "repository": "",