mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-09 06:25:07 +00:00
Build: Fix meta modules to not install as plugin in tests (#29150)
This commit fixes the meta plugin build to conditionally install the plugin as a module or plugin, depending on whether it is a module or plugin.
This commit is contained in:
parent
687577a516
commit
1eb1d59de8
@ -37,19 +37,28 @@ class MetaPluginBuildPlugin implements Plugin<Project> {
|
|||||||
project.plugins.apply(RestTestPlugin)
|
project.plugins.apply(RestTestPlugin)
|
||||||
|
|
||||||
createBundleTask(project)
|
createBundleTask(project)
|
||||||
|
boolean isModule = project.path.startsWith(':modules:')
|
||||||
|
|
||||||
project.integTestCluster {
|
project.integTestCluster {
|
||||||
dependsOn(project.bundlePlugin)
|
dependsOn(project.bundlePlugin)
|
||||||
plugin(project.path)
|
|
||||||
}
|
}
|
||||||
BuildPlugin.configurePomGeneration(project)
|
BuildPlugin.configurePomGeneration(project)
|
||||||
project.afterEvaluate {
|
project.afterEvaluate {
|
||||||
PluginBuildPlugin.addZipPomGeneration(project)
|
PluginBuildPlugin.addZipPomGeneration(project)
|
||||||
|
if (isModule) {
|
||||||
|
if (project.integTestCluster.distribution == 'integ-test-zip') {
|
||||||
|
project.integTestCluster.module(project)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
project.integTestCluster.plugin(project.path)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
RunTask run = project.tasks.create('run', RunTask)
|
RunTask run = project.tasks.create('run', RunTask)
|
||||||
run.dependsOn(project.bundlePlugin)
|
run.dependsOn(project.bundlePlugin)
|
||||||
run.clusterConfig.plugin(project.path)
|
if (isModule == false) {
|
||||||
|
run.clusterConfig.plugin(project.path)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void createBundleTask(Project project) {
|
private static void createBundleTask(Project project) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user