mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-03-02 00:49:11 +00:00
68 lines
1.7 KiB
Groovy
68 lines
1.7 KiB
Groovy
import org.elasticsearch.gradle.precommit.PrecommitTasks
|
|
import org.elastic.gradle.DownloadS3Task
|
|
|
|
apply plugin: 'elasticsearch.esplugin'
|
|
|
|
esplugin {
|
|
name 'prelert'
|
|
description 'Prelert Plugin'
|
|
classname 'org.elasticsearch.xpack.prelert.PrelertPlugin'
|
|
}
|
|
|
|
version = "${elasticsearchVersion}"
|
|
|
|
thirdPartyAudit.enabled = false
|
|
|
|
dependencies {
|
|
compile group: 'net.sf.supercsv', name: 'super-csv', version:"${supercsvVersion}"
|
|
testCompile group: 'org.ini4j', name: 'ini4j', version:'0.5.2'
|
|
}
|
|
|
|
test {
|
|
exclude '**/*NoBootstrapTests.class'
|
|
}
|
|
|
|
task noBootstrapTest(type: Test,
|
|
dependsOn: test.dependsOn) {
|
|
classpath = project.test.classpath
|
|
testClassesDir = project.test.testClassesDir
|
|
include '**/*NoBootstrapTests.class'
|
|
}
|
|
check.dependsOn noBootstrapTest
|
|
noBootstrapTest.mustRunAfter test
|
|
|
|
integTest {
|
|
cluster {
|
|
//setting 'useNativeProcess', 'true'
|
|
distribution = 'zip'
|
|
}
|
|
}
|
|
|
|
integTest.mustRunAfter noBootstrapTest
|
|
|
|
task downloadCppDist(type: DownloadS3Task) {
|
|
enabled project.cppEnabled == false
|
|
description = 'download cpp zips from S3 Bucket'
|
|
bucket 'prelert-artifacts'
|
|
destDir file("${buildDir}/cppDist")
|
|
flatten true
|
|
download "maven/${project.group}/prelert_cpp_darwin-x86_64/${elasticsearchVersion}/prelert_cpp_darwin-x86_64.zip"
|
|
}
|
|
|
|
bundlePlugin {
|
|
if (project.cppEnabled) {
|
|
from { zipTree(project(':cpp').buildZip.outputs.files.singleFile) }
|
|
} else {
|
|
from("${rootDir}/cppdistribution") {
|
|
into '.'
|
|
// Don't copy Windows import libraries
|
|
exclude "**/*.lib"
|
|
// Don't copy the test support library
|
|
exclude "**/libPreTest.*"
|
|
includeEmptyDirs = false
|
|
}
|
|
}
|
|
}
|
|
|
|
bundlePlugin.dependsOn([':cpp:buildZip', 'downloadCppDist'])
|