SpringBoot 引入第三方本地jar依赖 并打包

引入本地jar

  在项目路径下新建文件夹lib,并将jar放入

 

pom文件引入

<dependency>
            <groupId>com.aliyun.alicom</groupId>
            <artifactId>alicom-mns-receive-sdk</artifactId>
            <version>0.0.1-SNAPSHOT</version>
            <type>jar</type>
            <scope>system</scope>
            <systemPath>${project.basedir}/lib/alicom-mns-receive-sdk-1.0.1.jar</systemPath>
        </dependency>
        <dependency>
            <groupId>com.aliyun.mns</groupId>
            <artifactId>aliyun-sdk-mns</artifactId>
            <version>1.1.8</version>
            <type>jar</type>
            <scope>system</scope>
            <systemPath>${project.basedir}/lib/aliyun-sdk-mns-1.1.8.jar</systemPath>
        </dependency>

配置package带入

 <build>
        <plugins>
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <configuration>
                    <includeSystemScope>true</includeSystemScope>
                </configuration> 
            </plugin>
        </plugins>
    </build>

 

posted @ 2021-04-01 15:46  陈彦斌  阅读(504)  评论(0)    收藏  举报