2016-03-21 21:03:13 +00:00
|
|
|
<!--
|
|
|
|
Licensed to the Apache Software Foundation (ASF) under one or more
|
|
|
|
contributor license agreements. See the NOTICE file distributed with
|
|
|
|
this work for additional information regarding copyright ownership.
|
|
|
|
The ASF licenses this file to You under the Apache License, Version 2.0
|
|
|
|
(the "License"); you may not use this file except in compliance with
|
|
|
|
the License. You may obtain a copy of the License at
|
|
|
|
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
See the License for the specific language governing permissions and
|
|
|
|
limitations under the License.
|
|
|
|
-->
|
|
|
|
|
|
|
|
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
|
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
|
|
|
<parent>
|
|
|
|
<artifactId>hadoop-yarn</artifactId>
|
|
|
|
<groupId>org.apache.hadoop</groupId>
|
2017-09-01 18:53:48 +00:00
|
|
|
<version>3.1.0-SNAPSHOT</version>
|
2016-03-21 21:03:13 +00:00
|
|
|
</parent>
|
|
|
|
<modelVersion>4.0.0</modelVersion>
|
|
|
|
<artifactId>hadoop-yarn-ui</artifactId>
|
2017-09-01 18:53:48 +00:00
|
|
|
<version>3.1.0-SNAPSHOT</version>
|
2016-03-21 21:03:13 +00:00
|
|
|
<name>Apache Hadoop YARN UI</name>
|
2017-06-04 16:35:14 +00:00
|
|
|
<packaging>${packagingType}</packaging>
|
2016-03-21 21:03:13 +00:00
|
|
|
|
|
|
|
<properties>
|
2017-06-04 16:35:14 +00:00
|
|
|
<packagingType>pom</packagingType>
|
|
|
|
|
|
|
|
<webappDir>${basedir}/target/webapp</webappDir>
|
|
|
|
<nodeExecutable>${basedir}/target/webapp/node/node</nodeExecutable>
|
|
|
|
<packageManagerScript>node/yarn/dist/bin/yarn.js</packageManagerScript>
|
|
|
|
|
|
|
|
<keepUIBuildCache>false</keepUIBuildCache>
|
2016-03-21 21:03:13 +00:00
|
|
|
</properties>
|
|
|
|
|
|
|
|
<build>
|
|
|
|
<plugins>
|
|
|
|
<!-- Apache RAT -->
|
|
|
|
<plugin>
|
|
|
|
<groupId>org.apache.rat</groupId>
|
|
|
|
<artifactId>apache-rat-plugin</artifactId>
|
|
|
|
<configuration>
|
|
|
|
<excludes>
|
|
|
|
<exclude>src/main/webapp/jsconfig.json</exclude>
|
|
|
|
<exclude>src/main/webapp/bower.json</exclude>
|
2017-06-04 16:35:14 +00:00
|
|
|
<exclude>src/main/webapp/bower-shrinkwrap.json</exclude>
|
2016-03-21 21:03:13 +00:00
|
|
|
<exclude>src/main/webapp/package.json</exclude>
|
2017-06-04 16:35:14 +00:00
|
|
|
<exclude>src/main/webapp/yarn.lock</exclude>
|
2016-03-21 21:03:13 +00:00
|
|
|
<exclude>src/main/webapp/testem.json</exclude>
|
|
|
|
<exclude>src/main/webapp/public/assets/images/**/*</exclude>
|
2016-08-30 15:28:35 +00:00
|
|
|
<exclude>src/main/webapp/public/assets/images/*</exclude>
|
2016-03-21 21:03:13 +00:00
|
|
|
<exclude>src/main/webapp/public/robots.txt</exclude>
|
|
|
|
<exclude>public/crossdomain.xml</exclude>
|
2016-08-30 15:28:35 +00:00
|
|
|
<exclude>src/main/webapp/.bowerrc</exclude>
|
|
|
|
<exclude>src/main/webapp/.ember-cli</exclude>
|
|
|
|
<exclude>src/main/webapp/.jshintrc</exclude>
|
|
|
|
<exclude>src/main/webapp/.watchmanconfig</exclude>
|
2017-06-04 16:35:14 +00:00
|
|
|
<exclude>src/main/webapp/WEB-INF/wro.xml</exclude>
|
2016-03-21 21:03:13 +00:00
|
|
|
</excludes>
|
|
|
|
</configuration>
|
|
|
|
</plugin>
|
|
|
|
|
|
|
|
<plugin>
|
2016-08-25 17:51:29 +00:00
|
|
|
<artifactId>maven-clean-plugin</artifactId>
|
|
|
|
<version>3.0.0</version>
|
|
|
|
<configuration>
|
2017-06-04 16:35:14 +00:00
|
|
|
<skip>${keepUIBuildCache}</skip>
|
2016-08-25 17:51:29 +00:00
|
|
|
<followSymLinks>false</followSymLinks>
|
|
|
|
<filesets>
|
|
|
|
<fileset>
|
2017-06-04 16:35:14 +00:00
|
|
|
<directory>${webappDir}/bower_components</directory>
|
2016-08-25 17:51:29 +00:00
|
|
|
</fileset>
|
|
|
|
<fileset>
|
2017-06-04 16:35:14 +00:00
|
|
|
<directory>${webappDir}/node_modules</directory>
|
2016-08-25 17:51:29 +00:00
|
|
|
</fileset>
|
|
|
|
</filesets>
|
|
|
|
</configuration>
|
2016-03-21 21:03:13 +00:00
|
|
|
</plugin>
|
|
|
|
</plugins>
|
|
|
|
</build>
|
|
|
|
|
|
|
|
<profiles>
|
|
|
|
<profile>
|
|
|
|
<id>yarn-ui</id>
|
|
|
|
|
|
|
|
<activation>
|
|
|
|
<activeByDefault>false</activeByDefault>
|
|
|
|
</activation>
|
|
|
|
|
|
|
|
<properties>
|
2017-06-04 16:35:14 +00:00
|
|
|
<packagingType>war</packagingType>
|
2016-03-21 21:03:13 +00:00
|
|
|
</properties>
|
|
|
|
|
|
|
|
<build>
|
|
|
|
<plugins>
|
2017-06-04 16:35:14 +00:00
|
|
|
<!-- Copy files into target for build -->
|
2016-10-04 15:37:42 +00:00
|
|
|
<plugin>
|
2017-06-04 16:35:14 +00:00
|
|
|
<artifactId>maven-resources-plugin</artifactId>
|
2016-10-04 15:37:42 +00:00
|
|
|
<executions>
|
|
|
|
<execution>
|
2017-06-04 16:35:14 +00:00
|
|
|
<id>copy-resources</id>
|
|
|
|
<!-- here the phase you need -->
|
|
|
|
<phase>validate</phase>
|
2016-10-04 15:37:42 +00:00
|
|
|
<goals>
|
2017-06-04 16:35:14 +00:00
|
|
|
<goal>copy-resources</goal>
|
2016-10-04 15:37:42 +00:00
|
|
|
</goals>
|
|
|
|
<configuration>
|
2017-06-04 16:35:14 +00:00
|
|
|
<outputDirectory>${webappDir}</outputDirectory>
|
|
|
|
<resources>
|
|
|
|
<resource>
|
|
|
|
<directory>${basedir}/src/main/webapp</directory>
|
|
|
|
<filtering>true</filtering>
|
|
|
|
<excludes>
|
|
|
|
<exclude>node_modules/**/*</exclude>
|
|
|
|
<exclude>bower_components/**/*</exclude>
|
|
|
|
<exclude>tmp/**/*</exclude>
|
|
|
|
<exclude>dist/**/*</exclude>
|
|
|
|
</excludes>
|
|
|
|
</resource>
|
|
|
|
</resources>
|
2016-10-04 15:37:42 +00:00
|
|
|
</configuration>
|
|
|
|
</execution>
|
|
|
|
</executions>
|
|
|
|
</plugin>
|
|
|
|
|
2017-06-04 16:35:14 +00:00
|
|
|
<!-- Install Node, Yarn, Bower & dependencies -->
|
2016-03-21 21:03:13 +00:00
|
|
|
<plugin>
|
2017-03-04 07:43:25 +00:00
|
|
|
<groupId>com.github.eirslett</groupId>
|
|
|
|
<artifactId>frontend-maven-plugin</artifactId>
|
2017-06-04 16:35:14 +00:00
|
|
|
<version>1.2</version>
|
2017-03-04 07:43:25 +00:00
|
|
|
<configuration>
|
2017-06-04 16:35:14 +00:00
|
|
|
<workingDirectory>${webappDir}</workingDirectory>
|
2017-03-04 07:43:25 +00:00
|
|
|
</configuration>
|
2016-03-21 21:03:13 +00:00
|
|
|
<executions>
|
2017-06-04 16:35:14 +00:00
|
|
|
|
|
|
|
<!-- Install all dependencies -->
|
2016-03-21 21:03:13 +00:00
|
|
|
<execution>
|
2017-06-04 16:35:14 +00:00
|
|
|
<phase>generate-resources</phase>
|
|
|
|
<id>install node and yarn</id>
|
2016-03-21 21:03:13 +00:00
|
|
|
<goals>
|
2017-06-04 16:35:14 +00:00
|
|
|
<goal>install-node-and-yarn</goal>
|
2016-03-21 21:03:13 +00:00
|
|
|
</goals>
|
|
|
|
<configuration>
|
2017-06-04 16:35:14 +00:00
|
|
|
<nodeVersion>v5.12.0</nodeVersion>
|
|
|
|
<yarnVersion>v0.21.3</yarnVersion>
|
2016-03-21 21:03:13 +00:00
|
|
|
</configuration>
|
|
|
|
</execution>
|
2017-03-04 07:43:25 +00:00
|
|
|
<execution>
|
2017-06-04 16:35:14 +00:00
|
|
|
<phase>generate-resources</phase>
|
|
|
|
<id>yarn install</id>
|
2017-03-04 07:43:25 +00:00
|
|
|
<goals>
|
2017-06-04 16:35:14 +00:00
|
|
|
<goal>yarn</goal>
|
2017-03-04 07:43:25 +00:00
|
|
|
</goals>
|
2017-06-04 16:35:14 +00:00
|
|
|
<configuration>
|
|
|
|
<arguments>install</arguments>
|
|
|
|
</configuration>
|
2017-03-04 07:43:25 +00:00
|
|
|
</execution>
|
2016-03-21 21:03:13 +00:00
|
|
|
<execution>
|
2017-06-04 16:35:14 +00:00
|
|
|
<phase>generate-resources</phase>
|
2016-03-21 21:03:13 +00:00
|
|
|
<id>bower install</id>
|
2017-06-04 16:35:14 +00:00
|
|
|
<configuration>
|
|
|
|
<arguments>install</arguments>
|
|
|
|
</configuration>
|
2016-03-21 21:03:13 +00:00
|
|
|
<goals>
|
2017-03-04 07:43:25 +00:00
|
|
|
<goal>bower</goal>
|
2016-03-21 21:03:13 +00:00
|
|
|
</goals>
|
|
|
|
</execution>
|
2017-03-04 07:43:25 +00:00
|
|
|
</executions>
|
|
|
|
</plugin>
|
|
|
|
|
|
|
|
<plugin>
|
|
|
|
<groupId>org.codehaus.mojo</groupId>
|
2017-06-04 16:35:14 +00:00
|
|
|
<artifactId>exec-maven-plugin</artifactId>
|
2017-03-04 07:43:25 +00:00
|
|
|
<executions>
|
2017-06-04 16:35:14 +00:00
|
|
|
|
|
|
|
<!-- Build -->
|
2016-03-21 21:03:13 +00:00
|
|
|
<execution>
|
|
|
|
<id>ember build</id>
|
2017-06-04 16:35:14 +00:00
|
|
|
<phase>generate-resources</phase>
|
2016-03-21 21:03:13 +00:00
|
|
|
<goals>
|
|
|
|
<goal>exec</goal>
|
|
|
|
</goals>
|
|
|
|
<configuration>
|
2017-06-04 16:35:14 +00:00
|
|
|
<workingDirectory>${webappDir}</workingDirectory>
|
|
|
|
<executable>${nodeExecutable}</executable>
|
2016-03-21 21:03:13 +00:00
|
|
|
<arguments>
|
2017-06-04 16:35:14 +00:00
|
|
|
<argument>${packageManagerScript}</argument>
|
2017-03-15 10:23:57 +00:00
|
|
|
<argument>run</argument>
|
|
|
|
<argument>build:mvn</argument>
|
2016-03-21 21:03:13 +00:00
|
|
|
</arguments>
|
|
|
|
</configuration>
|
|
|
|
</execution>
|
2017-06-04 16:35:14 +00:00
|
|
|
|
2016-03-21 21:03:13 +00:00
|
|
|
</executions>
|
|
|
|
</plugin>
|
|
|
|
|
2017-06-04 16:35:14 +00:00
|
|
|
<!-- Asset minifier -->
|
|
|
|
<plugin>
|
|
|
|
<groupId>ro.isdc.wro4j</groupId>
|
|
|
|
<artifactId>wro4j-maven-plugin</artifactId>
|
|
|
|
<version>1.7.9</version>
|
|
|
|
<executions>
|
|
|
|
<execution>
|
|
|
|
<phase>prepare-package</phase>
|
|
|
|
<goals>
|
|
|
|
<goal>run</goal>
|
|
|
|
</goals>
|
|
|
|
</execution>
|
|
|
|
</executions>
|
|
|
|
<configuration>
|
|
|
|
<minimize>true</minimize>
|
|
|
|
<targetGroups>yarn-ui,vendor</targetGroups>
|
|
|
|
<destinationFolder>${basedir}/target/minified-resources/assets</destinationFolder>
|
|
|
|
<contextFolder>${webappDir}/dist/assets</contextFolder>
|
|
|
|
<wroFile>${webappDir}/WEB-INF/wro.xml</wroFile>
|
|
|
|
</configuration>
|
|
|
|
</plugin>
|
|
|
|
|
2016-03-21 21:03:13 +00:00
|
|
|
<!-- Package into war -->
|
|
|
|
<plugin>
|
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
|
<artifactId>maven-war-plugin</artifactId>
|
2017-06-04 16:35:14 +00:00
|
|
|
<executions>
|
|
|
|
<execution>
|
|
|
|
<phase>package</phase>
|
|
|
|
</execution>
|
|
|
|
</executions>
|
2016-03-21 21:03:13 +00:00
|
|
|
<configuration>
|
2017-06-04 16:35:14 +00:00
|
|
|
<webXml>${webappDir}/WEB-INF/web.xml</webXml>
|
|
|
|
<warSourceDirectory>${webappDir}/dist</warSourceDirectory>
|
|
|
|
<webResources>
|
|
|
|
<resource>
|
|
|
|
<filtering>false</filtering>
|
|
|
|
<directory>${basedir}/target/minified-resources</directory>
|
|
|
|
</resource>
|
|
|
|
</webResources>
|
|
|
|
</configuration>
|
|
|
|
</plugin>
|
|
|
|
|
|
|
|
<plugin>
|
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
|
<artifactId>maven-jar-plugin</artifactId>
|
|
|
|
<configuration>
|
|
|
|
<skipIfEmpty>true</skipIfEmpty>
|
2016-03-21 21:03:13 +00:00
|
|
|
</configuration>
|
|
|
|
</plugin>
|
|
|
|
|
|
|
|
</plugins>
|
|
|
|
</build>
|
|
|
|
</profile>
|
|
|
|
</profiles>
|
2017-06-04 16:35:14 +00:00
|
|
|
|
2016-03-21 21:03:13 +00:00
|
|
|
</project>
|