Java 使用maven构建Spring启动映像找不到webapp资源
我有一个webapp文件夹,它被绑定到资源文件夹中Java 使用maven构建Spring启动映像找不到webapp资源,java,spring-boot,docker,maven,buildpack,Java,Spring Boot,Docker,Maven,Buildpack,我有一个webapp文件夹,它被绑定到资源文件夹中 <resource> <directory>src/main/webapp</directory> <targetPath>META-INF/resources</targetPath> </resource> 但是运行容器时,/workspace文件夹似乎不在搜索路径中 emf_1 | preResources: emf_1 | mainResour
<resource>
<directory>src/main/webapp</directory>
<targetPath>META-INF/resources</targetPath>
</resource>
但是运行容器时,/workspace
文件夹似乎不在搜索路径中
emf_1 | preResources:
emf_1 | mainResources:
emf_1 | file:/tmp/tomcat-docbase.8080.12873057264998195501/
emf_1 | classResources:
emf_1 | jarResources:
emf_1 | file:/workspace/BOOT-INF/lib/custom-faces-0.2.7.jar
emf_1 | file:/workspace/BOOT-INF/lib/primefaces-6.1.jar
emf_1 | file:/workspace/BOOT-INF/lib/jsf-impl-2.2.14.jar
emf_1 | file:/workspace/BOOT-INF/lib/swagger-ui-3.37.2.jar
emf_1 | postResources:
还使用了webapp层
[INFO] [creator] ===> EXPORTING
[INFO] [creator] Reusing layer 'paketo-buildpacks/ca-certificates:helper'
[INFO] [creator] Reusing layer 'paketo-buildpacks/bellsoft-liberica:helper'
[INFO] [creator] Reusing layer 'paketo-buildpacks/bellsoft-liberica:java-security-properties'
[INFO] [creator] Reusing layer 'paketo-buildpacks/bellsoft-liberica:jre'
[INFO] [creator] Reusing layer 'paketo-buildpacks/bellsoft-liberica:jvmkill'
[INFO] [creator] Reusing layer 'paketo-buildpacks/executable-jar:classpath'
[INFO] [creator] Reusing layer 'paketo-buildpacks/spring-boot:helper'
[INFO] [creator] Reusing layer 'paketo-buildpacks/spring-boot:spring-cloud-bindings'
[INFO] [creator] Reusing layer 'paketo-buildpacks/spring-boot:web-application-type'
你知道怎么回事吗?或者有人能给我举一个jsf项目的例子,在这个项目中构建镜像是有效的吗?为什么要配置
src/main/webapp META-INF/resources
?您在Maven?jar中定义了什么样的打包,因为构建映像不支持war
[INFO] [creator] ===> EXPORTING
[INFO] [creator] Reusing layer 'paketo-buildpacks/ca-certificates:helper'
[INFO] [creator] Reusing layer 'paketo-buildpacks/bellsoft-liberica:helper'
[INFO] [creator] Reusing layer 'paketo-buildpacks/bellsoft-liberica:java-security-properties'
[INFO] [creator] Reusing layer 'paketo-buildpacks/bellsoft-liberica:jre'
[INFO] [creator] Reusing layer 'paketo-buildpacks/bellsoft-liberica:jvmkill'
[INFO] [creator] Reusing layer 'paketo-buildpacks/executable-jar:classpath'
[INFO] [creator] Reusing layer 'paketo-buildpacks/spring-boot:helper'
[INFO] [creator] Reusing layer 'paketo-buildpacks/spring-boot:spring-cloud-bindings'
[INFO] [creator] Reusing layer 'paketo-buildpacks/spring-boot:web-application-type'