[英]Quarkus 2.0 maven build is not creating uber-jar for AWS lambda
I'm using Quarkus 2.0 to build uber-jar to be used as AWS lambda.我正在使用 Quarkus 2.0 构建 uber-jar 以用作 AWS lambda。 Maven build script is as follows:
Maven构建脚本如下:
<properties>
<quarkus.package.type>uber-jar</quarkus.package.type>
</properties>
<dependencies>
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-amazon-lambda</artifactId>
</dependency>
</dependencies>
<build>
<plugin>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-maven-plugin</artifactId>
<version>2.0.3.Final</version>
<executions>
<execution>
<goals>
<goal>build</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
I also needed to deploy an uber-jar to artifactory, for further deployment as AWS lambda.我还需要将一个 uber-jar 部署到 artifactory,以便进一步部署为 AWS lambda。 Finally I solved it with
build-helper-maven-plugin:attach-artifact
plugin.最后我用
build-helper-maven-plugin:attach-artifact
插件解决了这个问题。 It attached function.zip
to artifact in Nexus, so Jenkins was able to get the archive and deploy it to AWS.它将
function.zip
附加到 Nexus 中的工件,因此 Jenkins 能够获取存档并将其部署到 AWS。
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>3.2.0</version>
<executions>
<execution>
<id>attach-artifacts</id>
<phase>package</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<configuration>
<artifacts>
<artifact>
<file>./target/function.zip</file>
<type>zip</type>
</artifact>
</artifacts>
</configuration>
</execution>
</executions>
</plugin>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.