Skip to content

Commit

Permalink
Change ref to 2.1 for opensearch dahsboards (opensearch-project#2267)
Browse files Browse the repository at this point in the history
Signed-off-by: Sayali Gaikawad <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

versionincrement.yaml matrix test

Signed-off-by: pgodithi <[email protected]>

versionincrement.yaml matrix test

Signed-off-by: pgodithi <[email protected]>

versionincrement.yaml matrix test

Signed-off-by: pgodithi <[email protected]>

versionincrement.yaml matrix test

Signed-off-by: pgodithi <[email protected]>

versionincrement.yaml matrix test

Signed-off-by: pgodithi <[email protected]>

versionincrement.yaml matrix test

Signed-off-by: pgodithi <[email protected]>

versionincrement.yaml matrix test

Signed-off-by: pgodithi <[email protected]>

versionincrement.yaml matrix test

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

Add test manifest to check build job (opensearch-project#2273)

Signed-off-by: Sayali Gaikawad <[email protected]>

Set concurrent build limit for gradle check (opensearch-project#2274)

Signed-off-by: Peter Zhu <[email protected]>

Add test coverage xml and support 1.x gradle check (opensearch-project#2279)

* Add test coverage xml and support 1.x gradle check

Signed-off-by: Peter Zhu <[email protected]>

* Remove comments

Signed-off-by: Peter Zhu <[email protected]>

Add java args to 2.2.0 manifest (opensearch-project#2281)

Signed-off-by: Sayali Gaikawad <[email protected]>

Update downloadFromS3 lib env vars with credentials (opensearch-project#2278)

Signed-off-by: Sayali Gaikawad <[email protected]>

Update buildUploadManifestSHA lib env vars with credentials (opensearch-project#2277)

Signed-off-by: Sayali Gaikawad <[email protected]>

Update signArtifacts lib env vars with credentials (opensearch-project#2275)

Signed-off-by: Sayali Gaikawad <[email protected]>

[OSD][2.1] add functional test repo (opensearch-project#2282)

Signed-off-by: Kawika Avilla <[email protected]>

Change codecov xml name and move gradle check script to build repo (opensearch-project#2283)

* Change codecov xml name and move gradle check script to build repo

Signed-off-by: Peter Zhu <[email protected]>

* Add tests

Signed-off-by: Peter Zhu <[email protected]>

* Tweak tokens

Signed-off-by: Peter Zhu <[email protected]>

* Tweak jenkins codeCoverage.xml

Signed-off-by: Peter Zhu <[email protected]>

* Add codeCoverage.xml

Signed-off-by: Peter Zhu <[email protected]>

Add gradle cleanup before the checks (opensearch-project#2285)

Signed-off-by: Peter Zhu <[email protected]>

Update promoteArtifactsLib lib env vars with credentials (opensearch-project#2284)

* Resolve merge conflicts

Signed-off-by: Sayali Gaikawad <[email protected]>

Update remaining env vars with credentials in jenkins libraries  (opensearch-project#2286)

* Update getManifestSHA lib env vars with credentials

Signed-off-by: Sayali Gaikawad <[email protected]>

Remove 2.1.0 from cron for building release candidates (opensearch-project#2287)

Signed-off-by: Sayali Gaikawad <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

Version increment automation

Signed-off-by: pgodithi <[email protected]>

Version increment automation

Signed-off-by: pgodithi <[email protected]>

Version increment automation

Signed-off-by: pgodithi <[email protected]>

Version increment automation

Signed-off-by: pgodithi <[email protected]>

Version increment automation

Signed-off-by: pgodithi <[email protected]>

Version increment automation

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test versionmatrixtest.yaml

Signed-off-by: pgodithi <[email protected]>

test version increment automation

Signed-off-by: pgodithi <[email protected]>

test version increment automation

Signed-off-by: pgodithi <[email protected]>

Staging version increment automation

Signed-off-by: pgodithi <[email protected]>

Staging version increment automation

Signed-off-by: pgodithi <[email protected]>

Staging version increment automation

Signed-off-by: pgodithi <[email protected]>

version increment automation

Signed-off-by: pgodithi <[email protected]>
  • Loading branch information
gaiksaya authored and prudhvigodithi committed Jul 5, 2022
1 parent 3d7637a commit 8d90ae6
Show file tree
Hide file tree
Showing 42 changed files with 1,045 additions and 656 deletions.
75 changes: 75 additions & 0 deletions .github/workflows/versionincrement.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
---
name: Version Increment
on:
workflow_dispatch:
inputs:
logLevel:
description: Log level
required: true
default: warning
type: choice
options:
- info
- warning
- debug

jobs:
plugin-version-increment-sync:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
repo: [common-utils, job-scheduler, ml-commons, performance-analyzer, security, alerting, index-management, sql, observability, asynchronous-search, k-NN, anomaly-detection, cross-cluster-replication, dashboards-reports]
branch: [{opensearch_branch: 1.3, plugin_branch: 1.3}]
# exclude:
# - {repo: notifications, branch: {opensearch_branch: "1.x", plugin_branch: "1.x"}}
# - {repo: notifications, branch: {opensearch_branch: "1.3", plugin_branch: "1.3"}}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: Check out OpenSearch repo
uses: actions/checkout@v3
with:
repository: opensearch-project/OpenSearch
ref: ${{ matrix.branch.opensearch_branch }}
- name: Fetch OpenSearch version
run: |
OPENSEARCH_VERSION=$(cat buildSrc/version.properties | grep opensearch | cut -d= -f2 | grep -oE '[0-9.]+')
OPENSEARCH_VERSION=$OPENSEARCH_VERSION-SNAPSHOT
echo "OPENSEARCH_VERSION=$OPENSEARCH_VERSION" >> $GITHUB_ENV
echo "OPENSEARCH_VERSION_NUMBER=$OPENSEARCH_VERSION" | cut -f1 -d"-" >> $GITHUB_ENV
- name: Check out plugin repo
uses: actions/checkout@v3
with:
repository: prudhvigodithi/${{ matrix.repo }}
ref: ${{ matrix.branch.plugin_branch }}
- name: version comparision
run: |
OPENSEARCH_EXISTING_VERSION=$(grep opensearch.version gradle.properties | cut -d'=' -f 2-)
echo "OPENSEARCH_EXISTING_VERSION=$OPENSEARCH_EXISTING_VERSION" >> $GITHUB_ENV
echo "OPENSEARCH_EXISTING_VERSION_NUMBER=$OPENSEARCH_EXISTING_VERSION" | cut -f1 -d"-" >> $GITHUB_ENV
- name: Version Increment plugin repo
if: env.OPENSEARCH_EXISTING_VERSION_NUMBER != env.OPENSEARCH_VERSION_NUMBER
run: |
echo "OpenSearch Core repo version on branch ${{ matrix.branch.opensearch_branch }} is ${{ env.OPENSEARCH_VERSION_NUMBER }}"
echo "OpenSearch version for ${{ matrix.repo }} on branch ${{ matrix.branch.plugin_branch }} is ${{ env.OPENSEARCH_EXISTING_VERSION_NUMBER }}"
./gradlew setVersion -PnewVersion=${{ env.OPENSEARCH_VERSION }}
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
if: env.OPENSEARCH_EXISTING_VERSION_NUMBER != env.OPENSEARCH_VERSION_NUMBER
with:
token: ${{ secrets.PAT }}
author: opensearch-ci-bot <[email protected]>
commit-message: |
Version Increment.
Signed-off-by: opensearch-ci-bot <[email protected]>
delete-branch: true
branch: create-pull-request/${{ env.OPENSEARCH_VERSION }}
title: '[AUTO] Version Increment to ${{ env.OPENSEARCH_VERSION }}'
body: |
- Version Increment from **${{ env.OPENSEARCH_EXISTING_VERSION }}** to **${{ env.OPENSEARCH_VERSION }}**.
- name: Check outputs
run: |-
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}"
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"
2 changes: 0 additions & 2 deletions jenkins/check-for-build.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ pipeline {
triggers {
parameterizedCron '''
H 1 * * * %INPUT_MANIFEST=2.2.0/opensearch-2.2.0.yml;TARGET_JOB_NAME=distribution-build-opensearch
H/10 * * * * %INPUT_MANIFEST=2.1.0/opensearch-2.1.0.yml;TARGET_JOB_NAME=distribution-build-opensearch
H/10 * * * * %INPUT_MANIFEST=2.1.0/opensearch-dashboards-2.1.0.yml;TARGET_JOB_NAME=distribution-build-opensearch-dashboards
H 1 * * * %INPUT_MANIFEST=3.0.0/opensearch-3.0.0.yml;TARGET_JOB_NAME=distribution-build-opensearch
H 1 * * * %INPUT_MANIFEST=3.0.0/opensearch-dashboards-3.0.0.yml;TARGET_JOB_NAME=distribution-build-opensearch-dashboards
H 1 * * * %INPUT_MANIFEST=2.0.2/opensearch-dashboards-2.0.2.yml;TARGET_JOB_NAME=distribution-build-opensearch-dashboards
Expand Down
16 changes: 13 additions & 3 deletions jenkins/gradle/gradle-check.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,16 @@ lib = library(identifier: 'jenkins@20211123', retriever: legacySCM(scm))

pipeline {
options {
timeout(time: 2, unit: 'HOURS')
timeout(time: 2, unit: 'HOURS')
throttleJobProperty(
categories: [],
limitOneJobWithMatchingParams: false,
maxConcurrentPerNode: 0,
maxConcurrentTotal: 50,
paramsToUseForLimit: '',
throttleEnabled: true,
throttleOption: 'project',
)
}
// gradle check have a lot of issues running on containers
// Therefore, we directly run it on the agent node
Expand Down Expand Up @@ -45,7 +54,6 @@ pipeline {
JAVA11_HOME="/var/jenkins/tools/hudson.model.JDK/jdk-11"
JAVA17_HOME="/var/jenkins/tools/hudson.model.JDK/jdk-17"
JAVA8_HOME="/var/jenkins/tools/hudson.model.JDK/jdk-8"
JAVA_HOME="/var/jenkins/tools/hudson.model.JDK/jdk-17"
USER_BUILD_CAUSE = currentBuild.getBuildCauses('hudson.model.Cause$UserIdCause')
TIMER_BUILD_CAUSE = currentBuild.getBuildCauses('hudson.triggers.TimerTrigger$TimerTriggerCause')
}
Expand Down Expand Up @@ -80,7 +88,7 @@ pipeline {
stage('Run Gradle Check') {
steps {
script {
sh("ls /var/jenkins/tools/hudson.model.JDK/ && env | grep JAVA")
sh("ls /var/jenkins/tools/hudson.model.JDK/")
if (env.USER_BUILD_CAUSE.equals('[]') && env.TIMER_BUILD_CAUSE.equals('[]')) {
def pr_url = "${pr_to_clone_url}".replace(".git", "/pull/${pr_number}")
println("Triggered by PR: ${pr_url}")
Expand All @@ -105,6 +113,8 @@ pipeline {
}
post() {
always {
sh ("cp -v `find search/build/reports/jacoco/ -name '*.xml' | head -n 1` codeCoverage.xml || echo")
archiveArtifacts artifacts: 'codeCoverage.xml', onlyIfSuccessful: true
script {
sh("rm -rf *")
postCleanup()
Expand Down
25 changes: 15 additions & 10 deletions manifests/2.1.0/opensearch-dashboards-2.1.0.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,36 +9,41 @@ ci:
components:
- name: OpenSearch-Dashboards
repository: https://github.com/opensearch-project/OpenSearch-Dashboards.git
ref: 2.x
ref: '2.1'
checks:
- npm:package:version
- name: functionalTestDashboards
repository: https://github.com/opensearch-project/opensearch-dashboards-functional-test.git
ref: main
- name: notificationsDashboards
repository: https://github.com/opensearch-project/notifications.git
working_directory: dashboards-notifications
ref: main
ref: '2.1'
- name: queryWorkbenchDashboards
repository: https://github.com/opensearch-project/sql.git
working_directory: workbench
ref: main
ref: '2.1'
- name: observabilityDashboards
repository: https://github.com/opensearch-project/observability.git
working_directory: dashboards-observability
ref: main
ref: '2.1'
- name: ganttChartDashboards
repository: https://github.com/opensearch-project/dashboards-visualizations.git
working_directory: gantt-chart
ref: main
ref: '2.1'
- name: reportsDashboards
repository: https://github.com/opensearch-project/dashboards-reports.git
working_directory: dashboards-reports
ref: main
ref: '2.1'
- name: securityDashboards
repository: https://github.com/opensearch-project/security-dashboards-plugin.git
ref: main
ref: '2.1'
- name: alertingDashboards
repository: https://github.com/opensearch-project/alerting-dashboards-plugin.git
ref: main
ref: '2.1'
- name: anomalyDetectionDashboards
repository: https://github.com/opensearch-project/anomaly-detection-dashboards-plugin
ref: main
ref: '2.1'
- name: indexManagementDashboards
repository: https://github.com/opensearch-project/index-management-dashboards-plugin.git
ref: main
ref: '2.1'
1 change: 1 addition & 0 deletions manifests/2.2.0/opensearch-2.2.0.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ build:
ci:
image:
name: opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2
args: -e JAVA_HOME=/opt/java/openjdk-17
components:
- name: OpenSearch
repository: https://github.com/opensearch-project/OpenSearch.git
Expand Down
69 changes: 69 additions & 0 deletions scripts/gradle/gradle-check.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
#!/bin/bash


# SPDX-License-Identifier: Apache-2.0
#
# The OpenSearch Contributors require contributions made to
# this file be licensed under the Apache-2.0 license or a
# compatible open source license.

# This script is used in OpenSearch Core repo github actions
# To trigger Jenkins Gradle Check from a PR


JENKINS_URL="https://build.ci.opensearch.org"
TIMEPASS=0
TIMEOUT=7200
RESULT="null"
TRIGGER_TOKEN=$1
PAYLOAD_JSON="{\"pr_from_sha\": \"$pr_from_sha\", \"pr_from_clone_url\": \"$pr_from_clone_url\", \"pr_to_clone_url\": \"$pr_to_clone_url\", \"pr_title\": \"$pr_title\", \"pr_number\": \"$pr_number\"}"

echo "Trigger Jenkins workflows"
JENKINS_REQ=`curl -s -XPOST \
-H "Authorization: Bearer $TRIGGER_TOKEN" \
-H "Content-Type: application/json" \
"$JENKINS_URL/generic-webhook-trigger/invoke" \
--data "$(echo $PAYLOAD_JSON)"`

echo $PAYLOAD_JSON | jq
echo $JENKINS_REQ

QUEUE_URL=$(echo $JENKINS_REQ | jq --raw-output '.jobs."gradle-check".url')
echo QUEUE_URL $QUEUE_URL
echo "wait for jenkins to start workflow" && sleep 15

echo "Check if queue exist in Jenkins after triggering"
if [ -z "$QUEUE_URL" ] || [ "$QUEUE_URL" != "null" ]; then
WORKFLOW_URL=$(curl -s -XGET ${JENKINS_URL}/${QUEUE_URL}api/json | jq --raw-output .executable.url)
echo WORKFLOW_URL $WORKFLOW_URL

echo "Use queue information to find build number in Jenkins if available"
if [ -z "$WORKFLOW_URL" ] || [ "$WORKFLOW_URL" != "null" ]; then

RUNNING="true"

echo "Waiting for Jenkins to complete the run"
while [ "$RUNNING" = "true" ] && [ "$TIMEPASS" -le "$TIMEOUT" ]; do
echo "Still running, wait for another 30 seconds before checking again, max timeout $TIMEOUT"
echo "Jenkins Workflow Url: $WORKFLOW_URL"
TIMEPASS=$(( TIMEPASS + 30 )) && echo time pass: $TIMEPASS
sleep 30
RUNNING=$(curl -s -XGET ${WORKFLOW_URL}api/json | jq --raw-output .building)
done

echo "Complete the run, checking results now......"
RESULT=$(curl -s -XGET ${WORKFLOW_URL}api/json | jq --raw-output .result)

fi
fi

echo "Please check jenkins url for logs: $WORKFLOW_URL"

if [ "$RESULT" != "SUCCESS" ]; then
echo "Result: $RESULT"
exit 1
else
echo "Result: $RESULT"
echo "Get codeCoverage.xml" && curl -SLO ${WORKFLOW_URL}artifact/codeCoverage.xml
echo 0
fi
2 changes: 1 addition & 1 deletion tests/jenkins/TestCCRPerfTest.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ class TestCCRPerfTest extends BuildPipelineTest {

assertThat(s3DownloadCommands.size(), equalTo(1))
assertThat(s3DownloadCommands, hasItem(
"{file=config.yml, bucket=test_bucket, path=test_config/config-ccr.yml, force=true}".toString()
"{file=config.yml, bucket=ARTIFACT_BUCKET_NAME, path=test_config/config-ccr.yml, force=true}".toString()
))
}

Expand Down
21 changes: 10 additions & 11 deletions tests/jenkins/TestPromoteArtifacts.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -29,28 +29,27 @@ class TestPromoteArtifacts extends BuildPipelineTest {

binding.setVariable('PUBLIC_ARTIFACT_URL', 'https://ci.opensearch.org/dbc')
binding.setVariable('DISTRIBUTION_JOB_NAME', 'vars-build')
binding.setVariable('ARTIFACT_BUCKET_NAME', 'artifact-bucket')
binding.setVariable('AWS_ACCOUNT_PUBLIC', 'account')
binding.setVariable('STAGE_NAME', 'stage')
binding.setVariable('BUILD_URL', 'http://jenkins.us-east-1.elb.amazonaws.com/job/vars/42')
binding.setVariable('DISTRIBUTION_BUILD_NUMBER', '33')
binding.setVariable('DISTRIBUTION_PLATFORM', 'linux')
binding.setVariable('DISTRIBUTION_ARCHITECTURE', 'x64')
binding.setVariable('ARTIFACT_DOWNLOAD_ROLE_NAME', 'downloadRoleName')
binding.setVariable('AWS_ACCOUNT_PUBLIC', 'publicAccount')
binding.setVariable('ARTIFACT_PROMOTION_ROLE_NAME', 'artifactPromotionRole')
binding.setVariable('AWS_ACCOUNT_ARTIFACT', 'artifactsAccount')
binding.setVariable('ARTIFACT_PRODUCTION_BUCKET_NAME', 'prod-bucket-name')
binding.setVariable('WORKSPACE', 'tests/jenkins')
binding.setVariable('GITHUB_BOT_TOKEN_NAME', 'github_bot_token_name')
binding.setVariable('SIGNER_CLIENT_ROLE', 'dummy_signer_client_role')
binding.setVariable('SIGNER_CLIENT_EXTERNAL_ID', 'signer_client_external_id')
binding.setVariable('SIGNER_CLIENT_UNSIGNED_BUCKET', 'signer_client_unsigned_bucket')
binding.setVariable('SIGNER_CLIENT_SIGNED_BUCKET', 'signer_client_signed_bucket')
def signer_client_creds = ["role": "dummy_role",
"external_id": "dummy_ID",
"unsigned_bucket": "dummy_unsigned_bucket",
"signed_bucket": "dummy_signed_bucket"]
binding.setVariable('configs', signer_client_creds)
helper.registerAllowedMethod("readJSON", [Map.class], {c -> signer_client_creds})

helper.registerAllowedMethod("git", [Map])
helper.registerAllowedMethod("s3Download", [Map])
helper.registerAllowedMethod("s3Upload", [Map])
helper.registerAllowedMethod("withCredentials", [Map, Closure], { args, closure ->
closure.delegate = delegate
return helper.callClosure(closure)
})
helper.registerAllowedMethod("withAWS", [Map, Closure], { args, closure ->
closure.delegate = delegate
return helper.callClosure(closure)
Expand Down
17 changes: 10 additions & 7 deletions tests/jenkins/TestPromoteYumRepos.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,18 @@ class TestPromoteYumRepos extends BuildPipelineTest {
super.setUp()

binding.setVariable('PUBLIC_ARTIFACT_URL', 'https://ci.opensearch.org/dbc')
binding.setVariable('ARTIFACT_PROMOTION_ROLE_NAME', 'artifactPromotionRole')
binding.setVariable('AWS_ACCOUNT_ARTIFACT', 'artifactsAccount')
binding.setVariable('ARTIFACT_PRODUCTION_BUCKET_NAME', 'prod-bucket-name')
binding.setVariable('GITHUB_BOT_TOKEN_NAME', 'github_bot_token_name')
binding.setVariable('SIGNER_CLIENT_ROLE', 'dummy_signer_client_role')
binding.setVariable('SIGNER_CLIENT_EXTERNAL_ID', 'signer_client_external_id')
binding.setVariable('SIGNER_CLIENT_UNSIGNED_BUCKET', 'signer_client_unsigned_bucket')
binding.setVariable('SIGNER_CLIENT_SIGNED_BUCKET', 'signer_client_signed_bucket')
def signer_client_creds = ["role": "dummy_role",
"external_id": "dummy_ID",
"unsigned_bucket": "dummy_unsigned_bucket",
"signed_bucket": "dummy_signed_bucket"]
binding.setVariable('configs', signer_client_creds)
helper.registerAllowedMethod("readJSON", [Map.class], {c -> signer_client_creds})
helper.registerAllowedMethod("git", [Map])
helper.registerAllowedMethod("withCredentials", [Map, Closure], { args, closure ->
closure.delegate = delegate
return helper.callClosure(closure)
})
helper.registerAllowedMethod("withAWS", [Map, Closure], { args, closure ->
closure.delegate = delegate
return helper.callClosure(closure)
Expand Down
2 changes: 1 addition & 1 deletion tests/jenkins/TestRunNonSecurityPerfTestScript.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class TestRunNonSecurityPerfTestScript extends BuildPipelineTest {

assertThat(s3DownloadCommands.size(), equalTo(1))
assertThat(s3DownloadCommands, hasItem(
"{file=config.yml, bucket=test_bucket, path=test_config/config.yml, force=true}".toString()
"{file=config.yml, bucket=ARTIFACT_BUCKET_NAME, path=test_config/config.yml, force=true}".toString()
))
}

Expand Down
2 changes: 1 addition & 1 deletion tests/jenkins/TestRunPerfTestScript.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class TestRunPerfTestScript extends BuildPipelineTest {

assertThat(s3DownloadCommands.size(), equalTo(2))
assertThat(s3DownloadCommands, hasItem(
"{file=config.yml, bucket=test_bucket, path=test_config/config.yml, force=true}".toString()
"{file=config.yml, bucket=ARTIFACT_BUCKET_NAME, path=test_config/config.yml, force=true}".toString()
))
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,11 @@
pipenv install "aws-cdk.core~=1.143.0" "aws_cdk.aws_ec2~=1.143.0" "aws_cdk.aws_iam~=1.143.0"
pipenv install "boto3~=1.18" "setuptools~=57.4" "retry~=0.9"
)
runPerfTestScript.withAWS({role=opensearch-test, roleAccount=dummy_account, duration=900, roleSessionName=jenkins-session}, groovy.lang.Closure)
runPerfTestScript.s3Download({file=config.yml, bucket=test_bucket, path=test_config/config-ccr.yml, force=true})
runPerfTestScript.string({credentialsId=jenkins-aws-account-public, variable=AWS_ACCOUNT_PUBLIC})
runPerfTestScript.string({credentialsId=jenkins-artifact-bucket-name, variable=ARTIFACT_BUCKET_NAME})
runPerfTestScript.withCredentials([AWS_ACCOUNT_PUBLIC, ARTIFACT_BUCKET_NAME], groovy.lang.Closure)
runPerfTestScript.withAWS({role=opensearch-test, roleAccount=AWS_ACCOUNT_PUBLIC, duration=900, roleSessionName=jenkins-session}, groovy.lang.Closure)
runPerfTestScript.s3Download({file=config.yml, bucket=ARTIFACT_BUCKET_NAME, path=test_config/config-ccr.yml, force=true})
runPerfTestScript.usernamePassword({credentialsId=bot_token_name, usernameVariable=GITHUB_USER, passwordVariable=GITHUB_TOKEN})
runPerfTestScript.withCredentials([[GITHUB_USER, GITHUB_TOKEN]], groovy.lang.Closure)
runPerfTestScript.sh(./test.sh perf-test --stack test-single-security-1236-x64-perf-test --bundle-manifest tests/jenkins/data/opensearch-1.3.0-bundle.yml --config config.yml --component cross-cluster-replication)
Expand Down
Loading

0 comments on commit 8d90ae6

Please sign in to comment.