Skip to content

Commit

Permalink
download security keys only if -Dsecurity.enabled==true (#680) (#682)
Browse files Browse the repository at this point in the history
* download security keys only if -Dsecurity.enabled==true

Signed-off-by: Varun Jain <[email protected]>

* Reverting HybridQueryPhaseSearchTests

Signed-off-by: Varun Jain <[email protected]>

---------

Signed-off-by: Varun Jain <[email protected]>
(cherry picked from commit ff95604)

Co-authored-by: Varun Jain <[email protected]>
  • Loading branch information
1 parent 5488f3d commit 0abb958
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -76,12 +76,15 @@ ext {
currentBundleVersion = opensearch_version.replace("-SNAPSHOT","")

// Config below including files are copied from security demo configuration
['esnode.pem', 'esnode-key.pem', 'root-ca.pem','kirk.pem','kirk-key.pem'].forEach { file ->
File local = Paths.get(opensearch_tmp_dir.absolutePath, file).toFile()
download.run {
src "https://raw.githubusercontent.com/opensearch-project/security/main/bwc-test/src/test/resources/security/" + file
dest local
overwrite false
runIntegTestWithSecurityPlugin= System.getProperty("security.enabled")
if (runIntegTestWithSecurityPlugin == "true"){
['esnode.pem', 'esnode-key.pem', 'root-ca.pem','kirk.pem','kirk-key.pem'].forEach { file ->
File local = Paths.get(opensearch_tmp_dir.absolutePath, file).toFile()
download.run {
src "https://raw.githubusercontent.com/opensearch-project/security/main/bwc-test/src/test/resources/security/" + file
dest local
overwrite false
}
}
}

Expand Down

0 comments on commit 0abb958

Please sign in to comment.