tom.xu@informa.com 2 年 前
コミット
5cd25e9f6f
2 ファイル変更35 行追加25 行削除
  1. 8 10
      deploy.sh
  2. 27 15
      pom.xml

+ 8 - 10
dmhub_cbme.sh → deploy.sh

@@ -1,16 +1,16 @@
-#!/bin/bash 
+#!/bin/bash
 date=`date +%Y%m%d%H%M%S`
-CODE_PATH=/home/workspace/ifm-dmhub/
-APP=dmhub-cbme
+CODE_PATH=/home/workspace/createmodel-java/
+APP=model
 APP_NAME=${APP}".jar"
 cd ${CODE_PATH}
 echo "开始拉取最新代码"
 #首先进行编译
 git pull
 echo "开始编译"
-mvn clean package -pl dmhub-cbme -am -Dmaven.test.skip=true
+mvn clean package  -Dmaven.test.skip=true
 echo "编译完成-切换目录"
-cd dmhub-cbme/target/
+cd target/
 
 echo "切换完成- kill 进程"
 #获取pid
@@ -20,10 +20,8 @@ if [ ${tpid} ]; then
 	echo 'Kill Process!'
 	kill -9 $tpid
 fi
-echo "copy ifm-dmhub.jar to  /home/ifm-dmhub/dmbub-cbme"
-cp dmhub-cbme.jar /home/ifm-dmhub/dmbub-cbme/
-cd /home/ifm-dmhub/dmbub-cbme/
-nohup java -jar  ${APP_NAME} > dmhub-cbme.out 2>&1 &
+
+nohup java -jar  ${APP_NAME} > model.out 2>&1 &
 sleep 5
-tail -f dmhub-cbme.out
+tail -f model.out
 exit 0

+ 27 - 15
pom.xml

@@ -50,21 +50,21 @@
             <artifactId>poi-ooxml</artifactId>
             <version>4.1.2</version>
         </dependency>
-       <!-- <dependency>
-            <groupId>org.apache.poi</groupId>
-            <artifactId>poi</artifactId>
-            <version>3.17</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.poi</groupId>
-            <artifactId>poi-ooxml</artifactId>
-            <version>3.17</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.poi</groupId>
-            <artifactId>poi-ooxml-schemas</artifactId>
-            <version>4.1.2</version>
-        </dependency>-->
+        <!-- <dependency>
+             <groupId>org.apache.poi</groupId>
+             <artifactId>poi</artifactId>
+             <version>3.17</version>
+         </dependency>
+         <dependency>
+             <groupId>org.apache.poi</groupId>
+             <artifactId>poi-ooxml</artifactId>
+             <version>3.17</version>
+         </dependency>
+         <dependency>
+             <groupId>org.apache.poi</groupId>
+             <artifactId>poi-ooxml-schemas</artifactId>
+             <version>4.1.2</version>
+         </dependency>-->
         <dependency>
             <groupId>org.apache.commons</groupId>
             <artifactId>commons-lang3</artifactId>
@@ -92,10 +92,22 @@
     </dependencies>
 
     <build>
+        <finalName>model</finalName>
         <plugins>
             <plugin>
                 <groupId>org.springframework.boot</groupId>
                 <artifactId>spring-boot-maven-plugin</artifactId>
+                <configuration>
+                    <mainClass>ieven.server.webapp.WebappApplication</mainClass>
+                    <includeSystemScope>true</includeSystemScope>
+                </configuration>
+                <executions>
+                    <execution>
+                        <goals>
+                            <goal>repackage</goal>
+                        </goals>
+                    </execution>
+                </executions>
             </plugin>
         </plugins>
     </build>