From 93325004035a4753058765438188b65cf5a0ceb6 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Thu, 21 Mar 2024 14:23:29 +0200 Subject: [PATCH 01/23] Created explore pipeline for security solution quality gate --- ...security-solution-quality-gate-explore.yml | 34 +++++++++++++++++ .../locations.yml | 1 + .../security_solution_explore.yml | 37 +++++++++++++++++++ 3 files changed, 72 insertions(+) create mode 100644 .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml create mode 100644 .buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml new file mode 100644 index 0000000000000..c436131e95d63 --- /dev/null +++ b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml @@ -0,0 +1,34 @@ +# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json +apiVersion: backstage.io/v1alpha1 +kind: Resource +metadata: + name: kibana_serverless_security_solution_quality_gate_explore + description: Runs the serverless security solution tests for the Quality Gate +spec: + type: buildkite-pipeline + owner: 'group:kibana-operations' + implementation: + apiVersion: buildkite.elastic.dev/v1 + kind: Pipeline + metadata: + name: kibana_serverless_security_solution_quality_gate_explore + description: Runs the serverless security solution tests for the Quality Gate + spec: + env: + SLACK_NOTIFICATIONS_ENABLED: 'false' + repository: elastic/kibana + pipeline_file: .buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml + provider_settings: + build_branches: false + build_pull_requests: false + publish_commit_status: false + skip_pull_request_builds_for_existing_commits: false + trigger_mode: none + build_tags: false + teams: + kibana-operations: + access_level: MANAGE_BUILD_AND_READ + security-engineering-productivity: + access_level: MANAGE_BUILD_AND_READ + everyone: + access_level: BUILD_AND_READ diff --git a/.buildkite/pipeline-resource-definitions/locations.yml b/.buildkite/pipeline-resource-definitions/locations.yml index 30c1ffc34e41e..bd28eb06c4d72 100644 --- a/.buildkite/pipeline-resource-definitions/locations.yml +++ b/.buildkite/pipeline-resource-definitions/locations.yml @@ -7,3 +7,4 @@ spec: type: url targets: - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-migration-staging.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml diff --git a/.buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml b/.buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml new file mode 100644 index 0000000000000..da084e8a0bf68 --- /dev/null +++ b/.buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml @@ -0,0 +1,37 @@ +steps: + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/create_periodic_test_docker_image.sh + label: Build kibana image + key: build_image + agents: + queue: n2-16-spot + timeout_in_minutes: 60 + retry: + automatic: + - exit_status: "-1" + limit: 3 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/upload_image_metadata.sh + label: "Upload runtime info" + key: upload_runtime_info + depends_on: build_image + agents: + queue: n2-4-spot + timeout_in_minutes: 300 + retry: + automatic: + - exit_status: "*" + limit: 1 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:explore + depends_on: build_image + key: test_explore + label: 'Serverless MKI QA Explore - Security Solution Cypress Tests' + agents: + queue: n2-4-spot + # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. + timeout_in_minutes: 300 + parallelism: 4 + retry: + automatic: + - exit_status: '*' + limit: 1 From bc2fa63ec4e86d51a2db716693357888c78cf53d Mon Sep 17 00:00:00 2001 From: dkirchan <55240027+dkirchan@users.noreply.github.com> Date: Thu, 21 Mar 2024 14:28:19 +0200 Subject: [PATCH 02/23] Update .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml Co-authored-by: Alex Szabo --- ...kibana-serverless-security-solution-quality-gate-explore.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml index c436131e95d63..aa53fe7991cba 100644 --- a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml +++ b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml @@ -2,7 +2,7 @@ apiVersion: backstage.io/v1alpha1 kind: Resource metadata: - name: kibana_serverless_security_solution_quality_gate_explore + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-explore description: Runs the serverless security solution tests for the Quality Gate spec: type: buildkite-pipeline From a949cbc92d18bb323b7ba389d938e493fc959338 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Thu, 21 Mar 2024 14:30:22 +0200 Subject: [PATCH 03/23] Fixed owner of the pipeline --- ...kibana-serverless-security-solution-quality-gate-explore.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml index aa53fe7991cba..a8286f56fb0fd 100644 --- a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml +++ b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml @@ -6,7 +6,7 @@ metadata: description: Runs the serverless security solution tests for the Quality Gate spec: type: buildkite-pipeline - owner: 'group:kibana-operations' + owner: 'group:security-engineering-productivity' implementation: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline From cfa97f11af144038b04a86f939c5a5472f0ed727 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Thu, 21 Mar 2024 14:41:13 +0200 Subject: [PATCH 04/23] Updated agents field --- .../security_solution_explore.yml | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/.buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml b/.buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml index da084e8a0bf68..6e6470588d675 100644 --- a/.buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml +++ b/.buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml @@ -3,7 +3,11 @@ steps: label: Build kibana image key: build_image agents: - queue: n2-16-spot + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-16 + preemptible: true timeout_in_minutes: 60 retry: automatic: @@ -15,7 +19,11 @@ steps: key: upload_runtime_info depends_on: build_image agents: - queue: n2-4-spot + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true timeout_in_minutes: 300 retry: automatic: @@ -27,7 +35,11 @@ steps: key: test_explore label: 'Serverless MKI QA Explore - Security Solution Cypress Tests' agents: - queue: n2-4-spot + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. timeout_in_minutes: 300 parallelism: 4 From f6bc0bf30b11c73b7dd5c94879860e992a7dc4ce Mon Sep 17 00:00:00 2001 From: dkirchan Date: Thu, 21 Mar 2024 17:20:47 +0200 Subject: [PATCH 05/23] Added investigations team pipeline --- ...security-solution-quality-gate-explore.yml | 8 +-- ...y-solution-quality-gate-investigations.yml | 34 +++++++++++++ .../locations.yml | 1 + ....yml => mki_security_solution_explore.yml} | 0 .../mki_security_solution_investigations.yml | 49 +++++++++++++++++++ 5 files changed, 88 insertions(+), 4 deletions(-) create mode 100644 .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml rename .buildkite/pipelines/security_solution_quality_gate/{security_solution_explore.yml => mki_security_solution_explore.yml} (100%) create mode 100644 .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml index a8286f56fb0fd..ebde4cf4b41da 100644 --- a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml +++ b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml @@ -3,7 +3,7 @@ apiVersion: backstage.io/v1alpha1 kind: Resource metadata: name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-explore - description: Runs the serverless security solution tests for the Quality Gate + description: "[MKI] Executes Cypress tests for the Explore team" spec: type: buildkite-pipeline owner: 'group:security-engineering-productivity' @@ -11,13 +11,13 @@ spec: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: kibana_serverless_security_solution_quality_gate_explore - description: Runs the serverless security solution tests for the Quality Gate + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-explore + description: "[MKI] Executes Cypress tests for the Explore team" spec: env: SLACK_NOTIFICATIONS_ENABLED: 'false' repository: elastic/kibana - pipeline_file: .buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml + pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_explore.yml provider_settings: build_branches: false build_pull_requests: false diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml new file mode 100644 index 0000000000000..845fd760196db --- /dev/null +++ b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml @@ -0,0 +1,34 @@ +# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json +apiVersion: backstage.io/v1alpha1 +kind: Resource +metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-investigations + description: "[MKI] Executes Cypress tests for the Investigations team" +spec: + type: buildkite-pipeline + owner: 'group:security-engineering-productivity' + implementation: + apiVersion: buildkite.elastic.dev/v1 + kind: Pipeline + metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-investigations + description: "[MKI] Executes Cypress tests for the Investigations team" + spec: + env: + SLACK_NOTIFICATIONS_ENABLED: 'false' + repository: elastic/kibana + pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml + provider_settings: + build_branches: false + build_pull_requests: false + publish_commit_status: false + skip_pull_request_builds_for_existing_commits: false + trigger_mode: none + build_tags: false + teams: + kibana-operations: + access_level: MANAGE_BUILD_AND_READ + security-engineering-productivity: + access_level: MANAGE_BUILD_AND_READ + everyone: + access_level: BUILD_AND_READ diff --git a/.buildkite/pipeline-resource-definitions/locations.yml b/.buildkite/pipeline-resource-definitions/locations.yml index bd28eb06c4d72..33bd3f539d422 100644 --- a/.buildkite/pipeline-resource-definitions/locations.yml +++ b/.buildkite/pipeline-resource-definitions/locations.yml @@ -8,3 +8,4 @@ spec: targets: - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-migration-staging.yml - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml diff --git a/.buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_explore.yml similarity index 100% rename from .buildkite/pipelines/security_solution_quality_gate/security_solution_explore.yml rename to .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_explore.yml diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml new file mode 100644 index 0000000000000..51f8820c8d097 --- /dev/null +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml @@ -0,0 +1,49 @@ +steps: + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/create_periodic_test_docker_image.sh + label: Build kibana image + key: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-16 + preemptible: true + timeout_in_minutes: 60 + retry: + automatic: + - exit_status: "-1" + limit: 3 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/upload_image_metadata.sh + label: "Upload runtime info" + key: upload_runtime_info + depends_on: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + timeout_in_minutes: 300 + retry: + automatic: + - exit_status: "*" + limit: 1 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:investigations + depends_on: build_image + key: test_investigations + label: 'Serverless MKI QA Investigations - Security Solution Cypress Tests' + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. + timeout_in_minutes: 300 + parallelism: 8 + retry: + automatic: + - exit_status: '*' + limit: 1 \ No newline at end of file From d54e7e5906dac7e7fe6bc2a0377da98c210aac73 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Thu, 21 Mar 2024 17:29:34 +0200 Subject: [PATCH 06/23] Added rule management pipeline --- ...-solution-quality-gate-rule-management.yml | 34 ++++++++++ .../locations.yml | 1 + .../mki_security_solution_rule_management.yml | 67 +++++++++++++++++++ 3 files changed, 102 insertions(+) create mode 100644 .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml create mode 100644 .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml new file mode 100644 index 0000000000000..4dbd89baff5bc --- /dev/null +++ b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml @@ -0,0 +1,34 @@ +# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json +apiVersion: backstage.io/v1alpha1 +kind: Resource +metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-rule-management + description: "[MKI] Executes Cypress tests for the Rule Management team" +spec: + type: buildkite-pipeline + owner: 'group:security-engineering-productivity' + implementation: + apiVersion: buildkite.elastic.dev/v1 + kind: Pipeline + metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-rule-management + description: "[MKI] Executes Cypress tests for the Rule Management team" + spec: + env: + SLACK_NOTIFICATIONS_ENABLED: 'false' + repository: elastic/kibana + pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml + provider_settings: + build_branches: false + build_pull_requests: false + publish_commit_status: false + skip_pull_request_builds_for_existing_commits: false + trigger_mode: none + build_tags: false + teams: + kibana-operations: + access_level: MANAGE_BUILD_AND_READ + security-engineering-productivity: + access_level: MANAGE_BUILD_AND_READ + everyone: + access_level: BUILD_AND_READ diff --git a/.buildkite/pipeline-resource-definitions/locations.yml b/.buildkite/pipeline-resource-definitions/locations.yml index 33bd3f539d422..847e2e22557fe 100644 --- a/.buildkite/pipeline-resource-definitions/locations.yml +++ b/.buildkite/pipeline-resource-definitions/locations.yml @@ -9,3 +9,4 @@ spec: - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-migration-staging.yml - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml new file mode 100644 index 0000000000000..f4b7d5d8a8807 --- /dev/null +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml @@ -0,0 +1,67 @@ +steps: + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/create_periodic_test_docker_image.sh + label: Build kibana image + key: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-16 + preemptible: true + timeout_in_minutes: 60 + retry: + automatic: + - exit_status: "-1" + limit: 3 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/upload_image_metadata.sh + label: "Upload runtime info" + key: upload_runtime_info + depends_on: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + timeout_in_minutes: 300 + retry: + automatic: + - exit_status: "*" + limit: 1 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:rule_management + label: 'Serverless MKI QA Rule Management - Security Solution Cypress Tests' + depends_on: build_image + key: test_rule_management + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. + timeout_in_minutes: 300 + parallelism: 8 + retry: + automatic: + - exit_status: '*' + limit: 1 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:rule_management:prebuilt_rules + label: 'Serverless MKI QA Rule Management - Prebuilt Rules - Security Solution Cypress Tests' + depends_on: build_image + key: test_rule_management_prebuilt_rules + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. + timeout_in_minutes: 300 + parallelism: 4 + retry: + automatic: + - exit_status: '*' + limit: 1 \ No newline at end of file From 8f0859d8d475e9c2e5e93b8f1230b181e059baa8 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Thu, 21 Mar 2024 17:39:11 +0200 Subject: [PATCH 07/23] Added detection engine pipeline --- ...solution-quality-gate-detection-engine.yml | 34 +++++++ .../locations.yml | 1 + ...mki_security_solution_detection_engine.yml | 93 +++++++++++++++++++ 3 files changed, 128 insertions(+) create mode 100644 .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-detection-engine.yml create mode 100644 .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-detection-engine.yml b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-detection-engine.yml new file mode 100644 index 0000000000000..0a08c154eb79a --- /dev/null +++ b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-detection-engine.yml @@ -0,0 +1,34 @@ +# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json +apiVersion: backstage.io/v1alpha1 +kind: Resource +metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-detection-engine + description: "[MKI] Executes Cypress tests for the Detection Engine team" +spec: + type: buildkite-pipeline + owner: 'group:security-engineering-productivity' + implementation: + apiVersion: buildkite.elastic.dev/v1 + kind: Pipeline + metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-detection-engine + description: "[MKI] Executes Cypress tests for the Detection Engine team" + spec: + env: + SLACK_NOTIFICATIONS_ENABLED: 'false' + repository: elastic/kibana + pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml + provider_settings: + build_branches: false + build_pull_requests: false + publish_commit_status: false + skip_pull_request_builds_for_existing_commits: false + trigger_mode: none + build_tags: false + teams: + kibana-operations: + access_level: MANAGE_BUILD_AND_READ + security-engineering-productivity: + access_level: MANAGE_BUILD_AND_READ + everyone: + access_level: BUILD_AND_READ diff --git a/.buildkite/pipeline-resource-definitions/locations.yml b/.buildkite/pipeline-resource-definitions/locations.yml index 847e2e22557fe..cdb094c90488b 100644 --- a/.buildkite/pipeline-resource-definitions/locations.yml +++ b/.buildkite/pipeline-resource-definitions/locations.yml @@ -10,3 +10,4 @@ spec: - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-detection-engine.yml diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml new file mode 100644 index 0000000000000..11b1718b9390d --- /dev/null +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml @@ -0,0 +1,93 @@ +steps: + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/create_periodic_test_docker_image.sh + label: Build kibana image + key: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-16 + preemptible: true + timeout_in_minutes: 60 + retry: + automatic: + - exit_status: "-1" + limit: 3 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/upload_image_metadata.sh + label: "Upload runtime info" + key: upload_runtime_info + depends_on: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + timeout_in_minutes: 300 + retry: + automatic: + - exit_status: "*" + limit: 1 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:detection_engine + label: 'Serverless MKI QA Detection Engine - Security Solution Cypress Tests' + key: test_detection_engine + depends_on: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. + timeout_in_minutes: 300 + parallelism: 8 + retry: + automatic: + - exit_status: '*' + limit: 1 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:detection_engine:exceptions + label: 'Serverless MKI QA Detection Engine - Exceptions - Security Solution Cypress Tests' + key: test_detection_engine_exceptions + depends_on: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. + timeout_in_minutes: 300 + parallelism: 6 + retry: + automatic: + - exit_status: '*' + limit: 1 + + + + + + + + + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:explore + depends_on: build_image + key: test_explore + label: 'Serverless MKI QA Explore - Security Solution Cypress Tests' + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. + timeout_in_minutes: 300 + parallelism: 4 + retry: + automatic: + - exit_status: '*' + limit: 1 From bef02faafc41338550aad0a3258a6156142c1a10 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Thu, 21 Mar 2024 17:48:54 +0200 Subject: [PATCH 08/23] Added gen ai pipeline --- ...-security-solution-quality-gate-gen-ai.yml | 34 +++++++++++++ .../locations.yml | 1 + .../mki_security_solution_gen_ai.yml | 49 +++++++++++++++++++ 3 files changed, 84 insertions(+) create mode 100644 .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-gen-ai.yml create mode 100644 .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-gen-ai.yml b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-gen-ai.yml new file mode 100644 index 0000000000000..b6a0b0613f1dc --- /dev/null +++ b/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-gen-ai.yml @@ -0,0 +1,34 @@ +# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json +apiVersion: backstage.io/v1alpha1 +kind: Resource +metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-gen-ai + description: "[MKI] Executes Cypress tests for the Gen AI team" +spec: + type: buildkite-pipeline + owner: 'group:security-engineering-productivity' + implementation: + apiVersion: buildkite.elastic.dev/v1 + kind: Pipeline + metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-gen-ai + description: "[MKI] Executes Cypress tests for the Gen AI team" + spec: + env: + SLACK_NOTIFICATIONS_ENABLED: 'false' + repository: elastic/kibana + pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml + provider_settings: + build_branches: false + build_pull_requests: false + publish_commit_status: false + skip_pull_request_builds_for_existing_commits: false + trigger_mode: none + build_tags: false + teams: + kibana-operations: + access_level: MANAGE_BUILD_AND_READ + security-engineering-productivity: + access_level: MANAGE_BUILD_AND_READ + everyone: + access_level: BUILD_AND_READ diff --git a/.buildkite/pipeline-resource-definitions/locations.yml b/.buildkite/pipeline-resource-definitions/locations.yml index cdb094c90488b..3aac5a0676ac4 100644 --- a/.buildkite/pipeline-resource-definitions/locations.yml +++ b/.buildkite/pipeline-resource-definitions/locations.yml @@ -11,3 +11,4 @@ spec: - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-detection-engine.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-gen-ai.yml diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml new file mode 100644 index 0000000000000..442923fd28a23 --- /dev/null +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml @@ -0,0 +1,49 @@ +steps: + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/create_periodic_test_docker_image.sh + label: Build kibana image + key: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-16 + preemptible: true + timeout_in_minutes: 60 + retry: + automatic: + - exit_status: "-1" + limit: 3 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/upload_image_metadata.sh + label: "Upload runtime info" + key: upload_runtime_info + depends_on: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + timeout_in_minutes: 300 + retry: + automatic: + - exit_status: "*" + limit: 1 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:ai_assistant + label: 'Serverless MKI QA AI Assistant - Security Solution Cypress Tests' + depends_on: build_image + key: test_ai_assistant + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. + timeout_in_minutes: 300 + parallelism: 1 + retry: + automatic: + - exit_status: '*' + limit: 1 \ No newline at end of file From a9a1802b491de968bb89d5db7615e13e2e693015 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Thu, 21 Mar 2024 17:55:02 +0200 Subject: [PATCH 09/23] Finalized splitting pipelines / old ones are not removed --- .../locations.yml | 11 +++-- ...solution-quality-gate-detection-engine.yml | 0 ...solution-quality-gate-entity-analytics.yml | 34 +++++++++++++ ...security-solution-quality-gate-explore.yml | 0 ...-security-solution-quality-gate-gen-ai.yml | 0 ...y-solution-quality-gate-investigations.yml | 0 ...-solution-quality-gate-rule-management.yml | 0 ...mki_security_solution_entity_analytics.yml | 49 +++++++++++++++++++ 8 files changed, 89 insertions(+), 5 deletions(-) rename .buildkite/pipeline-resource-definitions/{ => security-solution-quality-gate}/kibana-serverless-security-solution-quality-gate-detection-engine.yml (100%) create mode 100644 .buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml rename .buildkite/pipeline-resource-definitions/{ => security-solution-quality-gate}/kibana-serverless-security-solution-quality-gate-explore.yml (100%) rename .buildkite/pipeline-resource-definitions/{ => security-solution-quality-gate}/kibana-serverless-security-solution-quality-gate-gen-ai.yml (100%) rename .buildkite/pipeline-resource-definitions/{ => security-solution-quality-gate}/kibana-serverless-security-solution-quality-gate-investigations.yml (100%) rename .buildkite/pipeline-resource-definitions/{ => security-solution-quality-gate}/kibana-serverless-security-solution-quality-gate-rule-management.yml (100%) create mode 100644 .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml diff --git a/.buildkite/pipeline-resource-definitions/locations.yml b/.buildkite/pipeline-resource-definitions/locations.yml index 3aac5a0676ac4..1c7e35f3dc7f9 100644 --- a/.buildkite/pipeline-resource-definitions/locations.yml +++ b/.buildkite/pipeline-resource-definitions/locations.yml @@ -7,8 +7,9 @@ spec: type: url targets: - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-migration-staging.yml - - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml - - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml - - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml - - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-detection-engine.yml - - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-gen-ai.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml + - https://github.com/elastic/kibana/blob/main/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-detection-engine.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml similarity index 100% rename from .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-detection-engine.yml rename to .buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml new file mode 100644 index 0000000000000..5962e9159a8a0 --- /dev/null +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml @@ -0,0 +1,34 @@ +# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json +apiVersion: backstage.io/v1alpha1 +kind: Resource +metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-entity-analytics + description: "[MKI] Executes Cypress tests for the Entity Analytics team" +spec: + type: buildkite-pipeline + owner: 'group:security-engineering-productivity' + implementation: + apiVersion: buildkite.elastic.dev/v1 + kind: Pipeline + metadata: + name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-entity-analytics + description: "[MKI] Executes Cypress tests for the Entity Analytics team" + spec: + env: + SLACK_NOTIFICATIONS_ENABLED: 'false' + repository: elastic/kibana + pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml + provider_settings: + build_branches: false + build_pull_requests: false + publish_commit_status: false + skip_pull_request_builds_for_existing_commits: false + trigger_mode: none + build_tags: false + teams: + kibana-operations: + access_level: MANAGE_BUILD_AND_READ + security-engineering-productivity: + access_level: MANAGE_BUILD_AND_READ + everyone: + access_level: BUILD_AND_READ diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml similarity index 100% rename from .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-explore.yml rename to .buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-gen-ai.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml similarity index 100% rename from .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-gen-ai.yml rename to .buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml similarity index 100% rename from .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-investigations.yml rename to .buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml diff --git a/.buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml similarity index 100% rename from .buildkite/pipeline-resource-definitions/kibana-serverless-security-solution-quality-gate-rule-management.yml rename to .buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml new file mode 100644 index 0000000000000..f91d429b90adc --- /dev/null +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml @@ -0,0 +1,49 @@ +steps: + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/create_periodic_test_docker_image.sh + label: Build kibana image + key: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-16 + preemptible: true + timeout_in_minutes: 60 + retry: + automatic: + - exit_status: "-1" + limit: 3 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/upload_image_metadata.sh + label: "Upload runtime info" + key: upload_runtime_info + depends_on: build_image + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + timeout_in_minutes: 300 + retry: + automatic: + - exit_status: "*" + limit: 1 + + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:entity_analytics + label: 'Serverless MKI QA Entity Analytics - Security Solution Cypress Tests' + depends_on: build_image + key: test_entity_analytics + agents: + image: family/kibana-ubuntu-2004 + imageProject: elastic-images-qa + provider: gcp + machineType: n2-standard-4 + preemptible: true + # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. + timeout_in_minutes: 300 + parallelism: 2 + retry: + automatic: + - exit_status: '*' + limit: 1 \ No newline at end of file From df057d5db08ecbc186dc8ccadd74044c9208a6df Mon Sep 17 00:00:00 2001 From: dkirchan Date: Tue, 26 Mar 2024 12:33:13 +0200 Subject: [PATCH 10/23] Removed explore from detection engine --- ...mki_security_solution_detection_engine.yml | 28 +------------------ 1 file changed, 1 insertion(+), 27 deletions(-) diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml index 11b1718b9390d..259d2e131a7a5 100644 --- a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml @@ -64,30 +64,4 @@ steps: retry: automatic: - exit_status: '*' - limit: 1 - - - - - - - - - - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:explore - depends_on: build_image - key: test_explore - label: 'Serverless MKI QA Explore - Security Solution Cypress Tests' - agents: - image: family/kibana-ubuntu-2004 - imageProject: elastic-images-qa - provider: gcp - machineType: n2-standard-4 - preemptible: true - # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. - timeout_in_minutes: 300 - parallelism: 4 - retry: - automatic: - - exit_status: '*' - limit: 1 + limit: 1 \ No newline at end of file From 8922e5bc6418bfb3116d34b43a5f89c7b0263459 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Tue, 26 Mar 2024 14:53:32 +0200 Subject: [PATCH 11/23] Added test suite per team in buildkite --- .../mki_security_solution_detection_engine.yml | 4 ++++ .../mki_security_solution_entity_analytics.yml | 2 ++ .../mki_security_solution_explore.yml | 2 ++ .../mki_security_solution_gen_ai.yml | 2 ++ .../mki_security_solution_investigations.yml | 2 ++ .../mki_security_solution_rule_management.yml | 4 ++++ 6 files changed, 16 insertions(+) diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml index 259d2e131a7a5..a138c15ad6986 100644 --- a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml @@ -34,6 +34,8 @@ steps: label: 'Serverless MKI QA Detection Engine - Security Solution Cypress Tests' key: test_detection_engine depends_on: build_image + env: + BK_TEST_SUITE_KEY: "serverless-cypress-detection-engine" agents: image: family/kibana-ubuntu-2004 imageProject: elastic-images-qa @@ -52,6 +54,8 @@ steps: label: 'Serverless MKI QA Detection Engine - Exceptions - Security Solution Cypress Tests' key: test_detection_engine_exceptions depends_on: build_image + env: + BK_TEST_SUITE_KEY: "serverless-cypress-detection-engine" agents: image: family/kibana-ubuntu-2004 imageProject: elastic-images-qa diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml index f91d429b90adc..9614f4e877f2d 100644 --- a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml @@ -34,6 +34,8 @@ steps: label: 'Serverless MKI QA Entity Analytics - Security Solution Cypress Tests' depends_on: build_image key: test_entity_analytics + env: + BK_TEST_SUITE_KEY: "serverless-cypress-entity-analytics" agents: image: family/kibana-ubuntu-2004 imageProject: elastic-images-qa diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_explore.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_explore.yml index 6e6470588d675..c1b0f849d9036 100644 --- a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_explore.yml +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_explore.yml @@ -34,6 +34,8 @@ steps: depends_on: build_image key: test_explore label: 'Serverless MKI QA Explore - Security Solution Cypress Tests' + env: + BK_TEST_SUITE_KEY: "serverless-cypress-explore" agents: image: family/kibana-ubuntu-2004 imageProject: elastic-images-qa diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml index 442923fd28a23..ee0fef579f1c6 100644 --- a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml @@ -34,6 +34,8 @@ steps: label: 'Serverless MKI QA AI Assistant - Security Solution Cypress Tests' depends_on: build_image key: test_ai_assistant + env: + BK_TEST_SUITE_KEY: "serverless-cypress-gen-ai" agents: image: family/kibana-ubuntu-2004 imageProject: elastic-images-qa diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml index 51f8820c8d097..8a5349fea578b 100644 --- a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml @@ -34,6 +34,8 @@ steps: depends_on: build_image key: test_investigations label: 'Serverless MKI QA Investigations - Security Solution Cypress Tests' + env: + BK_TEST_SUITE_KEY: "serverless-cypress-investigations" agents: image: family/kibana-ubuntu-2004 imageProject: elastic-images-qa diff --git a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml index f4b7d5d8a8807..1cff6dfe25767 100644 --- a/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml +++ b/.buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml @@ -34,6 +34,8 @@ steps: label: 'Serverless MKI QA Rule Management - Security Solution Cypress Tests' depends_on: build_image key: test_rule_management + env: + BK_TEST_SUITE_KEY: "serverless-cypress-rule-management" agents: image: family/kibana-ubuntu-2004 imageProject: elastic-images-qa @@ -52,6 +54,8 @@ steps: label: 'Serverless MKI QA Rule Management - Prebuilt Rules - Security Solution Cypress Tests' depends_on: build_image key: test_rule_management_prebuilt_rules + env: + BK_TEST_SUITE_KEY: "serverless-cypress-rule-management" agents: image: family/kibana-ubuntu-2004 imageProject: elastic-images-qa From c384548806442fa78e004b15561cedddc98ef6b7 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Tue, 26 Mar 2024 16:02:13 +0200 Subject: [PATCH 12/23] Fixed granularity of pipelines - Deleted old main cypress pipeline --- .../security_solution_cypress.yml | 123 ------------------ .../mki_security_solution_cypress.sh | 2 +- .../security_solution_cypress/pipeline.sh | 5 - .../security_solution_cypress/pipeline.ts | 40 ------ 4 files changed, 1 insertion(+), 169 deletions(-) delete mode 100644 .buildkite/pipelines/security_solution/security_solution_cypress.yml delete mode 100755 .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.sh delete mode 100644 .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.ts diff --git a/.buildkite/pipelines/security_solution/security_solution_cypress.yml b/.buildkite/pipelines/security_solution/security_solution_cypress.yml deleted file mode 100644 index 4d27fd954c110..0000000000000 --- a/.buildkite/pipelines/security_solution/security_solution_cypress.yml +++ /dev/null @@ -1,123 +0,0 @@ -steps: - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/create_periodic_test_docker_image.sh - label: Build kibana image - key: build_image - agents: - queue: n2-16-spot - timeout_in_minutes: 60 - retry: - automatic: - - exit_status: "-1" - limit: 3 - - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/upload_image_metadata.sh - label: "Upload runtime info" - key: upload_runtime_info - depends_on: build_image - agents: - queue: n2-4-spot - timeout_in_minutes: 300 - retry: - automatic: - - exit_status: "*" - limit: 1 - - - group: "Execute Tests" - depends_on: build_image - key: test_execution - steps: - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:explore - label: 'Serverless MKI QA Explore - Security Solution Cypress Tests' - agents: - queue: n2-4-spot - # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. - timeout_in_minutes: 300 - parallelism: 4 - retry: - automatic: - - exit_status: '*' - limit: 1 - - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:investigations - label: 'Serverless MKI QA Investigations - Security Solution Cypress Tests' - agents: - queue: n2-4-spot - # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. - timeout_in_minutes: 300 - parallelism: 8 - retry: - automatic: - - exit_status: '*' - limit: 1 - - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:rule_management - label: 'Serverless MKI QA Rule Management - Security Solution Cypress Tests' - agents: - queue: n2-4-spot - # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. - timeout_in_minutes: 300 - parallelism: 8 - retry: - automatic: - - exit_status: '*' - limit: 1 - - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:rule_management:prebuilt_rules - label: 'Serverless MKI QA Rule Management - Prebuilt Rules - Security Solution Cypress Tests' - agents: - queue: n2-4-spot - # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. - timeout_in_minutes: 300 - parallelism: 4 - retry: - automatic: - - exit_status: '*' - limit: 1 - - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:detection_engine - label: 'Serverless MKI QA Detection Engine - Security Solution Cypress Tests' - agents: - queue: n2-4-spot - # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. - timeout_in_minutes: 300 - parallelism: 8 - retry: - automatic: - - exit_status: '*' - limit: 1 - - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:detection_engine:exceptions - label: 'Serverless MKI QA Detection Engine - Exceptions - Security Solution Cypress Tests' - agents: - queue: n2-4-spot - # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. - timeout_in_minutes: 300 - parallelism: 6 - retry: - automatic: - - exit_status: '*' - limit: 1 - - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:ai_assistant - label: 'Serverless MKI QA AI Assistant - Security Solution Cypress Tests' - agents: - queue: n2-4-spot - # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. - timeout_in_minutes: 300 - parallelism: 1 - retry: - automatic: - - exit_status: '*' - limit: 1 - - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:entity_analytics - label: 'Serverless MKI QA Entity Analytics - Security Solution Cypress Tests' - agents: - queue: n2-4-spot - # TODO : Revise the timeout when the pipeline will be officially integrated with the quality gate. - timeout_in_minutes: 300 - parallelism: 2 - retry: - automatic: - - exit_status: '*' - limit: 1 \ No newline at end of file diff --git a/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh b/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh index 8cce28a1401df..cf0dc230b0f40 100755 --- a/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh +++ b/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh @@ -30,6 +30,6 @@ fi QA_API_KEY=$(vault_get security-solution-quality-gate qa_api_key) QA_CONSOLE_URL=$(vault_get security-solution-quality-gate qa_console_url) -BK_ANALYTICS_API_KEY=$(vault_get security-solution-quality-gate serverless-sec-sol-cypress-bk-api-key) +BK_ANALYTICS_API_KEY=$(vault_get security-solution-quality-gate $BK_TEST_SUITE_KEY) QA_CONSOLE_URL=$QA_CONSOLE_URL KIBANA_MKI_USE_LATEST_COMMIT=$KIBANA_OVERRIDE_FLAG BK_ANALYTICS_API_KEY=$BK_ANALYTICS_API_KEY CLOUD_QA_API_KEY=$QA_API_KEY yarn $1; status=$?; yarn junit:merge || :; exit $status diff --git a/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.sh b/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.sh deleted file mode 100755 index b3d93e083fa41..0000000000000 --- a/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -set -euo pipefail - -ts-node .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.ts diff --git a/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.ts b/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.ts deleted file mode 100644 index fb9ec67fba888..0000000000000 --- a/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.ts +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0 and the Server Side Public License, v 1; you may not use this file except - * in compliance with, at your election, the Elastic License 2.0 or the Server - * Side Public License, v 1. - */ - -import { execSync } from 'child_process'; -import fs from 'fs'; - -const getPipeline = (filename: string, removeSteps = true) => { - const str = fs.readFileSync(filename).toString(); - return removeSteps ? str.replace(/^steps:/, '') : str; -}; - -const uploadPipeline = (pipelineContent: string | object) => { - const str = - typeof pipelineContent === 'string' ? pipelineContent : JSON.stringify(pipelineContent); - - execSync('buildkite-agent pipeline upload', { - input: str, - stdio: ['pipe', 'inherit', 'inherit'], - }); -}; - -(async () => { - try { - const pipeline = []; - - pipeline.push( - getPipeline('.buildkite/pipelines/security_solution/security_solution_cypress.yml', false) - ); - // remove duplicated steps - uploadPipeline([...new Set(pipeline)].join('\n')); - } catch (ex) { - console.error('PR pipeline generation error', ex.message); - process.exit(1); - } -})(); From 65d0a5379f506c36a834360360b6232f21ecef69 Mon Sep 17 00:00:00 2001 From: dkirchan <55240027+dkirchan@users.noreply.github.com> Date: Tue, 26 Mar 2024 15:10:03 +0100 Subject: [PATCH 13/23] Update .buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml Co-authored-by: Alex Szabo --- ...erverless-security-solution-quality-gate-detection-engine.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml index 0a08c154eb79a..72f5df5f54836 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml @@ -7,6 +7,7 @@ metadata: spec: type: buildkite-pipeline owner: 'group:security-engineering-productivity' + system: buildkite implementation: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline From 31c930a3de9fb7c0f6a039431abad814611b5a85 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Tue, 26 Mar 2024 16:14:43 +0200 Subject: [PATCH 14/23] Removed slack nots - Renamed pipelines - Added system --- ...rless-security-solution-quality-gate-detection-engine.yml | 4 +--- ...rless-security-solution-quality-gate-entity-analytics.yml | 5 ++--- ...ana-serverless-security-solution-quality-gate-explore.yml | 5 ++--- ...bana-serverless-security-solution-quality-gate-gen-ai.yml | 5 ++--- ...verless-security-solution-quality-gate-investigations.yml | 5 ++--- ...erless-security-solution-quality-gate-rule-management.yml | 5 ++--- 6 files changed, 11 insertions(+), 18 deletions(-) diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml index 72f5df5f54836..bca3c44397d23 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml @@ -12,11 +12,9 @@ spec: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-detection-engine + name: kibana-serverless-security-solution-quality-gate-detection-engine description: "[MKI] Executes Cypress tests for the Detection Engine team" spec: - env: - SLACK_NOTIFICATIONS_ENABLED: 'false' repository: elastic/kibana pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml provider_settings: diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml index 5962e9159a8a0..045be6f109585 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml @@ -7,15 +7,14 @@ metadata: spec: type: buildkite-pipeline owner: 'group:security-engineering-productivity' + system: buildkite implementation: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-entity-analytics + name: kibana-serverless-security-solution-quality-gate-entity-analytics description: "[MKI] Executes Cypress tests for the Entity Analytics team" spec: - env: - SLACK_NOTIFICATIONS_ENABLED: 'false' repository: elastic/kibana pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_entity_analytics.yml provider_settings: diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml index ebde4cf4b41da..ecbbc650ec9a8 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml @@ -7,15 +7,14 @@ metadata: spec: type: buildkite-pipeline owner: 'group:security-engineering-productivity' + system: buildkite implementation: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-explore + name: kibana-serverless-security-solution-quality-gate-explore description: "[MKI] Executes Cypress tests for the Explore team" spec: - env: - SLACK_NOTIFICATIONS_ENABLED: 'false' repository: elastic/kibana pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_explore.yml provider_settings: diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml index b6a0b0613f1dc..e1bb45ecccf97 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml @@ -7,15 +7,14 @@ metadata: spec: type: buildkite-pipeline owner: 'group:security-engineering-productivity' + system: buildkite implementation: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-gen-ai + name: kibana-serverless-security-solution-quality-gate-gen-ai description: "[MKI] Executes Cypress tests for the Gen AI team" spec: - env: - SLACK_NOTIFICATIONS_ENABLED: 'false' repository: elastic/kibana pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_gen_ai.yml provider_settings: diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml index 845fd760196db..d7e86f0e3550d 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml @@ -7,15 +7,14 @@ metadata: spec: type: buildkite-pipeline owner: 'group:security-engineering-productivity' + system: buildkite implementation: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-investigations + name: kibana-serverless-security-solution-quality-gate-investigations description: "[MKI] Executes Cypress tests for the Investigations team" spec: - env: - SLACK_NOTIFICATIONS_ENABLED: 'false' repository: elastic/kibana pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_investigations.yml provider_settings: diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml index 4dbd89baff5bc..3bbbca5b42194 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml @@ -7,15 +7,14 @@ metadata: spec: type: buildkite-pipeline owner: 'group:security-engineering-productivity' + system: buildkite implementation: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: buildkite-pipeline-kibana-serverless-security-solution-quality-gate-rule-management + name: kibana-serverless-security-solution-quality-gate-rule-management description: "[MKI] Executes Cypress tests for the Rule Management team" spec: - env: - SLACK_NOTIFICATIONS_ENABLED: 'false' repository: elastic/kibana pipeline_file: .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_rule_management.yml provider_settings: From 9a82050ec33d79bd3da3b17dda2262c0014e994e Mon Sep 17 00:00:00 2001 From: dkirchan Date: Tue, 26 Mar 2024 17:28:44 +0200 Subject: [PATCH 15/23] Test upload pipeline --- .buildkite/pipelines/upload_pipeline.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.buildkite/pipelines/upload_pipeline.yml b/.buildkite/pipelines/upload_pipeline.yml index a6fa136efb2ed..0367e3a448c52 100644 --- a/.buildkite/pipelines/upload_pipeline.yml +++ b/.buildkite/pipelines/upload_pipeline.yml @@ -2,4 +2,5 @@ steps: - label: Upload tested pipeline - command: buildkite-agent pipeline upload .buildkite/pipelines/pipeline_to_test.yml + # command: buildkite-agent pipeline upload .buildkite/pipelines/pipeline_to_test.yml + command: buildkite-agent pipeline upload .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml From bc32d67bee2aa1ffe9b89b2f1aae85bdabe96713 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Wed, 27 Mar 2024 11:24:46 +0200 Subject: [PATCH 16/23] Fixed names of the pipelines --- ...rverless-security-solution-quality-gate-detection-engine.yml | 2 +- ...rverless-security-solution-quality-gate-entity-analytics.yml | 2 +- ...kibana-serverless-security-solution-quality-gate-explore.yml | 2 +- .../kibana-serverless-security-solution-quality-gate-gen-ai.yml | 2 +- ...serverless-security-solution-quality-gate-investigations.yml | 2 +- ...erverless-security-solution-quality-gate-rule-management.yml | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml index bca3c44397d23..8d181174f0e57 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-detection-engine.yml @@ -12,7 +12,7 @@ spec: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: kibana-serverless-security-solution-quality-gate-detection-engine + name: "Kibana / Serverless / Security Solution Quality Gate / Detection Engine" description: "[MKI] Executes Cypress tests for the Detection Engine team" spec: repository: elastic/kibana diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml index 045be6f109585..01e6d39be6e3e 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-entity-analytics.yml @@ -12,7 +12,7 @@ spec: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: kibana-serverless-security-solution-quality-gate-entity-analytics + name: "Kibana / Serverless / Security Solution Quality Gate / Entity Analytics" description: "[MKI] Executes Cypress tests for the Entity Analytics team" spec: repository: elastic/kibana diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml index ecbbc650ec9a8..d6e0c5a9fb148 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-explore.yml @@ -12,7 +12,7 @@ spec: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: kibana-serverless-security-solution-quality-gate-explore + name: "Kibana / Serverless / Security Solution Quality Gate / Explore" description: "[MKI] Executes Cypress tests for the Explore team" spec: repository: elastic/kibana diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml index e1bb45ecccf97..3cbf7a01da698 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-gen-ai.yml @@ -12,7 +12,7 @@ spec: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: kibana-serverless-security-solution-quality-gate-gen-ai + name: "Kibana / Serverless / Security Solution Quality Gate / Gen Ai" description: "[MKI] Executes Cypress tests for the Gen AI team" spec: repository: elastic/kibana diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml index d7e86f0e3550d..16d07e86d2ef1 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-investigations.yml @@ -12,7 +12,7 @@ spec: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: kibana-serverless-security-solution-quality-gate-investigations + name: "Kibana / Serverless / Security Solution Quality Gate / Investigations" description: "[MKI] Executes Cypress tests for the Investigations team" spec: repository: elastic/kibana diff --git a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml index 3bbbca5b42194..0dcd14a27b659 100644 --- a/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml +++ b/.buildkite/pipeline-resource-definitions/security-solution-quality-gate/kibana-serverless-security-solution-quality-gate-rule-management.yml @@ -12,7 +12,7 @@ spec: apiVersion: buildkite.elastic.dev/v1 kind: Pipeline metadata: - name: kibana-serverless-security-solution-quality-gate-rule-management + name: "Kibana / Serverless / Security Solution Quality Gate / Rule Management" description: "[MKI] Executes Cypress tests for the Rule Management team" spec: repository: elastic/kibana From 5bd81862af020171047102a31d47461ecac9a39a Mon Sep 17 00:00:00 2001 From: dkirchan Date: Wed, 27 Mar 2024 11:36:07 +0200 Subject: [PATCH 17/23] Restored upload_pipeline.yml --- .buildkite/pipelines/upload_pipeline.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.buildkite/pipelines/upload_pipeline.yml b/.buildkite/pipelines/upload_pipeline.yml index 0367e3a448c52..a6fa136efb2ed 100644 --- a/.buildkite/pipelines/upload_pipeline.yml +++ b/.buildkite/pipelines/upload_pipeline.yml @@ -2,5 +2,4 @@ steps: - label: Upload tested pipeline - # command: buildkite-agent pipeline upload .buildkite/pipelines/pipeline_to_test.yml - command: buildkite-agent pipeline upload .buildkite/pipelines/security_solution_quality_gate/mki_security_solution_detection_engine.yml + command: buildkite-agent pipeline upload .buildkite/pipelines/pipeline_to_test.yml From 55fa4e92ccb2f41556955428ba754414c1cab741 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Wed, 27 Mar 2024 11:54:38 +0200 Subject: [PATCH 18/23] Attemt to enable more logging for errors of axios --- .../scripts/run_cypress/parallel_serverless.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts index ece544ed836d9..09b9afd7c290b 100644 --- a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts +++ b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts @@ -140,7 +140,9 @@ async function createSecurityProject( }; } catch (error) { if (error instanceof AxiosError) { - log.error(`${error.response?.status}:${error.response?.data}`); + log.error( + `${error.response?.status}:${Object.values(error.response?.data.errors).flat().join()}` + ); } else { log.error(`${error.message}`); } From aa0312c7128958259f8035d41aad7f42ca76f2b0 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Wed, 27 Mar 2024 14:04:32 +0200 Subject: [PATCH 19/23] Added log to create project --- .../scripts/run_cypress/parallel_serverless.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts index 09b9afd7c290b..bf0c7fde2e3cf 100644 --- a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts +++ b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts @@ -140,9 +140,13 @@ async function createSecurityProject( }; } catch (error) { if (error instanceof AxiosError) { +<<<<<<< Updated upstream log.error( `${error.response?.status}:${Object.values(error.response?.data.errors).flat().join()}` ); +======= + console.log(`${error.response?.status}:${JSON.stringify(error.response?.data)}`); +>>>>>>> Stashed changes } else { log.error(`${error.message}`); } From 74a3ccb6fa0b6d07bea67708a3fec702594fa968 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Wed, 27 Mar 2024 15:27:10 +0200 Subject: [PATCH 20/23] Fixing conflict --- .../scripts/run_cypress/parallel_serverless.ts | 6 ------ 1 file changed, 6 deletions(-) diff --git a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts index bf0c7fde2e3cf..f4173300cff8b 100644 --- a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts +++ b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts @@ -140,13 +140,7 @@ async function createSecurityProject( }; } catch (error) { if (error instanceof AxiosError) { -<<<<<<< Updated upstream - log.error( - `${error.response?.status}:${Object.values(error.response?.data.errors).flat().join()}` - ); -======= console.log(`${error.response?.status}:${JSON.stringify(error.response?.data)}`); ->>>>>>> Stashed changes } else { log.error(`${error.message}`); } From b97d8f405f964b7f15e4f3a43a69ce7aaefc65eb Mon Sep 17 00:00:00 2001 From: dkirchan Date: Wed, 27 Mar 2024 15:29:23 +0200 Subject: [PATCH 21/23] Reverted change for logging --- .../scripts/run_cypress/parallel_serverless.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts index f4173300cff8b..ece544ed836d9 100644 --- a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts +++ b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts @@ -140,7 +140,7 @@ async function createSecurityProject( }; } catch (error) { if (error instanceof AxiosError) { - console.log(`${error.response?.status}:${JSON.stringify(error.response?.data)}`); + log.error(`${error.response?.status}:${error.response?.data}`); } else { log.error(`${error.message}`); } From 873cb403a90be1bf5c74b9f767f9aaf3317c2e60 Mon Sep 17 00:00:00 2001 From: dkirchan Date: Wed, 27 Mar 2024 17:09:38 +0200 Subject: [PATCH 22/23] Reintroducing the log line to debug project creation --- .../scripts/run_cypress/parallel_serverless.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts index ece544ed836d9..f4173300cff8b 100644 --- a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts +++ b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts @@ -140,7 +140,7 @@ async function createSecurityProject( }; } catch (error) { if (error instanceof AxiosError) { - log.error(`${error.response?.status}:${error.response?.data}`); + console.log(`${error.response?.status}:${JSON.stringify(error.response?.data)}`); } else { log.error(`${error.message}`); } From 039e26a277ea8726832fed98662d40a186a3d99c Mon Sep 17 00:00:00 2001 From: dkirchan Date: Wed, 27 Mar 2024 18:04:58 +0200 Subject: [PATCH 23/23] Fixed linting issue with the latest log change --- .../scripts/run_cypress/parallel_serverless.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts index f4173300cff8b..adb07a228d528 100644 --- a/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts +++ b/x-pack/plugins/security_solution/scripts/run_cypress/parallel_serverless.ts @@ -140,7 +140,8 @@ async function createSecurityProject( }; } catch (error) { if (error instanceof AxiosError) { - console.log(`${error.response?.status}:${JSON.stringify(error.response?.data)}`); + const errorData = JSON.stringify(error.response?.data); + log.error(`${error.response?.status}:${errorData}`); } else { log.error(`${error.message}`); }