在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):OpenLiberty/ci.maven开源软件地址(OpenSource Url):https://github.com/OpenLiberty/ci.maven开源编程语言(OpenSource Language):Java 99.4%开源软件介绍(OpenSource Introduction):ci.mavenCollection of Maven plugins and archetypes for managing Open Liberty and WebSphere Liberty servers and applications. BuildUse Maven 3.5.0 or later to build the Liberty plugins and archetypes.
PluginsLiberty Maven PluginThe Liberty Maven Plugin provides a number of goals for managing a Liberty server and applications. Maven 3.5.0 or later is recommended to use the Liberty Maven Plugin. Release 3.0 differencesThe new capabilities and behavior differences are summarized in the Liberty Maven Plug-in 3.0 release notes. ConfigurationTo enable Liberty Maven Plugin in your project add the following to your <project>
...
<build>
<plugins>
<!-- Enable liberty-maven-plugin -->
<plugin>
<groupId>io.openliberty.tools</groupId>
<artifactId>liberty-maven-plugin</artifactId>
<version>3.6.1</version>
<!-- Specify configuration, executions for liberty-maven-plugin -->
...
</plugin>
</plugins>
</build>
...
</project> If you are using a snapshot version of Liberty Maven Plugin then you will also need to add the following plugin repository to your
Liberty installation configurationThe Liberty Maven Plugin must first be configured with the Liberty server installation information. The installation information can be specified as an existing installation directory, a packaged server, or as a Maven artifact. The Liberty Maven Plugin can also download and install a Liberty server from the Liberty repository or other location using the install parameter. By default, the plugin installs the Open Liberty runtime from Maven Central. GoalsThe Liberty Maven Plugin provides the following goals.
Common ParametersParameters shared by all goals. See common parameters. Common Server ParametersAdditional parameters shared by all server-based goals. See common server parameters. ExtensionsExtensions improve the compatibility or user experience of third party libraries used with Liberty. The Liberty Maven Plugin provides the following extensions.
Packaging typesliberty-assemblyThe The
Example: <project>
...
<groupId>myGroup</groupId>
<artifactId>myServer</artifactId>
<!-- Create Liberty server assembly -->
<packaging>liberty-assembly</packaging>
...
<dependencies>
<!-- Package SimpleServlet.war with server assembly -->
<dependency>
<groupId>wasdev</groupId>
<artifactId>SimpleServlet</artifactId>
<version>1.0</version>
<type>war</type>
</dependency>
</dependencies>
...
<build>
<plugins>
<!-- Enable liberty-maven-plugin -->
<plugin>
<groupId>io.openliberty.tools</groupId>
<artifactId>liberty-maven-plugin</artifactId>
<version>[3.2.3,)</version>
<extensions>true</extensions>
<configuration>
<installDirectory>/opt/ibm/wlp</installDirectory>
<serverName>test</serverName>
<features>
<acceptLicense>true</acceptLicense>
<feature>mongodb-2.0</feature>
</features>
<looseApplication>true</looseApplication>
<deployPackages>all</deployPackages>
</configuration>
</plugin>
</plugins>
</build>
...
</project> ArchetypesBy default, all archetypes that specify a Liberty runtime use the latest version of the Open Liberty runtime. You can use a different runtime by setting the The runtime version can also be set dynamically. For example, you can specify version Finally, the default Liberty Maven Plugin version is set to be the latest version of the plugin. To specify a different version of the plugin, use the liberty-plugin-archetypeThe Usage
liberty-archetype-webappThe Usage
liberty-archetype-earThe Usage
Using Archetype SnapshotsIf you are using a snapshot version of <settings>
...
<profiles>
<profile>
<id>archetype-snapshot-repo</id>
<properties>
<archetypeRepository>https://oss.sonatype.org/content/repositories/snapshots
</archetypeRepository>
</properties>
<repositories>
<repository>
<id>sonatype-nexus-snapshots</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://oss.sonatype.org/content/repositories/snapshots/
</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>sonatype-nexus-snapshots</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://oss.sonatype.org/content/repositories/snapshots/
</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<activeProfiles>
<activeProfile>archetype-snapshot-repo</activeProfile>
</activeProfiles>
</settings>
|
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论