Spirng Boot 使用本地 jar 包

添加依赖

		<dependency>
			<groupId>com.aspose</groupId>
			<artifactId>aspose-words</artifactId>
			<version>19.5.0</version>
			<scope>system</scope>
			<systemPath>${project.basedir}/src/main/resources/lib/aspose-words-19.5jdk.jar</systemPath>
		</dependency>

打包配置需要添加
includeSystemScope = true

<build>
		<finalName>xxx_api</finalName>
		<plugins>
			<plugin>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-maven-plugin</artifactId>
				<configuration>
					<mainClass>com.csdn.SystemApplication</mainClass>
					<includeSystemScope>true</includeSystemScope>
				</configuration>
			</plugin>
		</plugins>
	</build>

猜你喜欢

转载自blog.csdn.net/z1353095373/article/details/141320545
今日推荐