123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302 |
- <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/xsd/maven-4.0.0.xsd">
- <modelVersion>4.0.0</modelVersion>
- <parent>
- <groupId>org.thingsboard</groupId>
- <version>1.0.0-SNAPSHOT</version>
- <artifactId>msa</artifactId>
- </parent>
- <groupId>org.thingsboard.msa</groupId>
- <artifactId>web-ui</artifactId>
- <packaging>pom</packaging>
- <name>ThingsBoard Web UI Microservice</name>
- <url>https://thingsboard.io</url>
- <description>Service for hosting ThingsBoard Web UI</description>
- <properties>
- <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
- <main.dir>${basedir}/../..</main.dir>
- <pkg.name>tb-web-ui</pkg.name>
- <pkg.type>js</pkg.type>
- <docker.name>tb-web-ui</docker.name>
- <pkg.name>tb-web-ui</pkg.name>
- <pkg.type>js</pkg.type>
- <pkg.disabled>false</pkg.disabled>
- <pkg.process-resources.phase>process-resources</pkg.process-resources.phase>
- <pkg.package.phase>package</pkg.package.phase>
- <pkg.linux.dist>${project.build.directory}/package/linux</pkg.linux.dist>
- <pkg.win.dist>${project.build.directory}/package/windows</pkg.win.dist>
- <docker.push-arm-amd-image.phase>pre-integration-test</docker.push-arm-amd-image.phase>
- </properties>
- <dependencies>
- <dependency>
- <groupId>org.thingsboard</groupId>
- <artifactId>ui-ngx</artifactId>
- <version>${project.version}</version>
- <type>jar</type>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>com.sun.winsw</groupId>
- <artifactId>winsw</artifactId>
- <classifier>bin</classifier>
- <type>exe</type>
- <scope>provided</scope>
- </dependency>
- </dependencies>
- <build>
- <plugins>
- <plugin>
- <groupId>com.github.eirslett</groupId>
- <artifactId>frontend-maven-plugin</artifactId>
- <configuration>
- <installDirectory>target</installDirectory>
- <workingDirectory>${basedir}</workingDirectory>
- </configuration>
- <executions>
- <execution>
- <id>install node and yarn</id>
- <goals>
- <goal>install-node-and-yarn</goal>
- </goals>
- <configuration>
- <nodeVersion>v12.16.1</nodeVersion>
- <yarnVersion>v1.22.4</yarnVersion>
- </configuration>
- </execution>
- <execution>
- <id>yarn install</id>
- <goals>
- <goal>yarn</goal>
- </goals>
- <configuration>
- <arguments>install</arguments>
- </configuration>
- </execution>
- <execution>
- <id>yarn pkg</id>
- <goals>
- <goal>yarn</goal>
- </goals>
- <configuration>
- <arguments>run pkg</arguments>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-dependency-plugin</artifactId>
- <executions>
- <execution>
- <id>extract-web-ui</id>
- <goals>
- <goal>unpack</goal>
- </goals>
- <configuration>
- <artifactItems>
- <artifactItem>
- <groupId>org.thingsboard</groupId>
- <artifactId>ui-ngx</artifactId>
- <type>jar</type>
- <overWrite>false</overWrite>
- <outputDirectory>${project.build.directory}/web</outputDirectory>
- </artifactItem>
- </artifactItems>
- </configuration>
- </execution>
- <execution>
- <id>copy-winsw-service</id>
- <phase>package</phase>
- <goals>
- <goal>copy</goal>
- </goals>
- <configuration>
- <artifactItems>
- <artifactItem>
- <groupId>com.sun.winsw</groupId>
- <artifactId>winsw</artifactId>
- <classifier>bin</classifier>
- <type>exe</type>
- <destFileName>service.exe</destFileName>
- </artifactItem>
- </artifactItems>
- <outputDirectory>${pkg.win.dist}</outputDirectory>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-resources-plugin</artifactId>
- <executions>
- <execution>
- <id>copy-src-root</id>
- <phase>process-resources</phase>
- <goals>
- <goal>copy-resources</goal>
- </goals>
- <configuration>
- <outputDirectory>${project.build.directory}/src</outputDirectory>
- <resources>
- <resource>
- <directory>${basedir}</directory>
- <includes>
- <include>server.js</include>
- <include>package.json</include>
- <include>yarn.lock</include>
- </includes>
- <filtering>false</filtering>
- </resource>
- </resources>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.thingsboard</groupId>
- <artifactId>gradle-maven-plugin</artifactId>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-assembly-plugin</artifactId>
- </plugin>
- <plugin>
- <groupId>com.spotify</groupId>
- <artifactId>dockerfile-maven-plugin</artifactId>
- <executions>
- <execution>
- <id>build-docker-image</id>
- <phase>pre-integration-test</phase>
- <goals>
- <goal>build</goal>
- </goals>
- <configuration>
- <skip>${dockerfile.skip}</skip>
- <repository>${docker.repo}/${docker.name}</repository>
- <verbose>true</verbose>
- <googleContainerRegistryEnabled>false</googleContainerRegistryEnabled>
- <contextDirectory>${project.build.directory}</contextDirectory>
- </configuration>
- </execution>
- <execution>
- <id>tag-docker-image</id>
- <phase>pre-integration-test</phase>
- <goals>
- <goal>tag</goal>
- </goals>
- <configuration>
- <skip>${dockerfile.skip}</skip>
- <repository>${docker.repo}/${docker.name}</repository>
- <tag>${project.version}</tag>
- </configuration>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- <profiles>
- <profile>
- <id>yarn-start</id>
- <activation>
- <property>
- <name>yarn-start</name>
- </property>
- </activation>
- <build>
- <plugins>
- <plugin>
- <groupId>com.github.eirslett</groupId>
- <artifactId>frontend-maven-plugin</artifactId>
- <configuration>
- <installDirectory>target</installDirectory>
- <workingDirectory>${basedir}</workingDirectory>
- </configuration>
- <executions>
- <execution>
- <id>yarn start</id>
- <goals>
- <goal>yarn</goal>
- </goals>
- <configuration>
- <arguments>start</arguments>
- </configuration>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- </profile>
- <profile>
- <id>push-docker-image</id>
- <activation>
- <property>
- <name>push-docker-image</name>
- </property>
- </activation>
- <build>
- <plugins>
- <plugin>
- <groupId>com.spotify</groupId>
- <artifactId>dockerfile-maven-plugin</artifactId>
- <executions>
- <execution>
- <id>push-latest-docker-image</id>
- <phase>pre-integration-test</phase>
- <goals>
- <goal>push</goal>
- </goals>
- <configuration>
- <tag>latest</tag>
- <repository>${docker.repo}/${docker.name}</repository>
- </configuration>
- </execution>
- <execution>
- <id>push-version-docker-image</id>
- <phase>pre-integration-test</phase>
- <goals>
- <goal>push</goal>
- </goals>
- <configuration>
- <tag>${project.version}</tag>
- <repository>${docker.repo}/${docker.name}</repository>
- </configuration>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- </profile>
- </profiles>
- <repositories>
- <repository>
- <id>jenkins</id>
- <name>Jenkins Repository</name>
- <url>https://repo.jenkins-ci.org/releases</url>
- <snapshots>
- <enabled>false</enabled>
- </snapshots>
- </repository>
- </repositories>
- </project>
|