Skip to content

Commit

Permalink
Merge branch 'main' into edit-mode
Browse files Browse the repository at this point in the history
  • Loading branch information
angorayc authored Sep 6, 2023
2 parents f75afdb + 630a95b commit af66475
Show file tree
Hide file tree
Showing 1,241 changed files with 12,346 additions and 5,527 deletions.
4 changes: 0 additions & 4 deletions .buildkite/pipelines/on_merge_unsupported_ftrs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-solution/**/*"

- command: .buildkite/scripts/steps/functional/osquery_cypress.sh
label: 'Osquery Cypress Tests'
Expand All @@ -110,8 +108,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-osquery/**/*"

- command: .buildkite/scripts/steps/functional/synthetics_plugin.sh
label: 'Synthetics @elastic/synthetics Tests'
Expand Down
5 changes: 4 additions & 1 deletion .buildkite/pipelines/pipeline.kibana-serverless-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,11 @@ steps:
- label: ":releasethekraken: Release kibana"
# https://regex101.com/r/tY52jo/1
if: build.tag =~ /^deploy@\d+\$/
trigger: gpctl-promote
trigger: gpctl-promote-with-e2e-tests
build:
env:
SERVICE_COMMIT_HASH: "${BUILDKITE_COMMIT:0:12}"
REMOTE_SERVICE_CONFIG: https://raw.githubusercontent.com/elastic/serverless-gitops/main/gen/gpctl/kibana/config.yaml
SERVICE: kibana-controller
NAMESPACE: kibana-ci
IMAGE_NAME: kibana-serverless
10 changes: 1 addition & 9 deletions .buildkite/pipelines/pull_request/base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -140,14 +140,12 @@ steps:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 40
parallelism: 16
parallelism: 12
soft_fail: true
retry:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-solution/**/*"

# status_exception: Native role management is not enabled in this Elasticsearch instance
# - command: .buildkite/scripts/steps/functional/security_serverless_defend_workflows.sh
Expand All @@ -161,8 +159,6 @@ steps:
# automatic:
# - exit_status: '*'
# limit: 1
# artifact_paths:
# - "target/kibana-security-solution/**/*"

- command: .buildkite/scripts/steps/functional/security_serverless_investigations.sh
label: 'Serverless Security Investigations Cypress Tests'
Expand All @@ -176,8 +172,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-solution/**/*"

- command: .buildkite/scripts/steps/functional/security_serverless_explore.sh
label: 'Serverless Security Explore Cypress Tests'
Expand All @@ -191,8 +185,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-solution/**/*"

- command: .buildkite/scripts/steps/lint.sh
label: 'Linting'
Expand Down
4 changes: 0 additions & 4 deletions .buildkite/pipelines/pull_request/defend_workflows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-solution/**/*"

- command: .buildkite/scripts/steps/functional/defend_workflows_vagrant.sh
label: 'Defend Workflows Endpoint Cypress Tests'
Expand All @@ -24,5 +22,3 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-solution/**/*"
6 changes: 0 additions & 6 deletions .buildkite/pipelines/pull_request/osquery_cypress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-osquery/**/*"

- command: .buildkite/scripts/steps/functional/osquery_cypress_burn.sh
label: 'Osquery Cypress Tests, burning changed specs'
Expand All @@ -22,8 +20,6 @@ steps:
soft_fail: true
retry:
automatic: false
artifact_paths:
- "target/kibana-osquery/**/*"

# Error: self-signed certificate in certificate chain
# - command: .buildkite/scripts/steps/functional/security_serverless_osquery.sh
Expand All @@ -37,5 +33,3 @@ steps:
# automatic:
# - exit_status: '*'
# limit: 1
# artifact_paths:
# - "target/kibana-osquery/**/*"
2 changes: 0 additions & 2 deletions .buildkite/pipelines/pull_request/response_ops.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,3 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-solution/**/*"
2 changes: 0 additions & 2 deletions .buildkite/pipelines/pull_request/response_ops_cases.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,3 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-solution/**/*"
8 changes: 0 additions & 8 deletions .buildkite/pipelines/pull_request/security_solution.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- 'target/kibana-security-solution/**/*'

- command: .buildkite/scripts/steps/functional/security_solution_explore.sh
label: 'Explore - Security Solution Cypress Tests'
Expand All @@ -24,8 +22,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- 'target/kibana-security-solution/**/*'

- command: .buildkite/scripts/steps/functional/security_solution_investigations.sh
label: 'Investigations - Security Solution Cypress Tests'
Expand All @@ -38,8 +34,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- 'target/kibana-security-solution/**/*'

- command: .buildkite/scripts/steps/functional/security_solution_burn.sh
label: 'Security Solution Cypress tests, burning changed specs'
Expand All @@ -51,8 +45,6 @@ steps:
retry:
automatic: false
soft_fail: true
artifact_paths:
- 'target/kibana-security-solution/**/*'

- command: .buildkite/scripts/steps/code_generation/security_solution_codegen.sh
label: 'Security Solution OpenAPI codegen'
Expand Down
2 changes: 0 additions & 2 deletions .buildkite/pipelines/pull_request/threat_intelligence.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,3 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-threat-intelligence/**/*"
19 changes: 18 additions & 1 deletion .buildkite/pipelines/quality-gates/pipeline.kibana-tests.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,27 @@
# This pipeline serves as the entry point for your service's quality gates definitions. When
# properly configured, it will be invoked automatically as part of the automated
# promotion process once a new version was rolled out in one of the various cloud stages.
#
# The updated environment is provided via ENVIRONMENT variable. The seedling
# step will branch and execute pipeline snippets at the following location:
# pipeline.tests-qa.yaml
# pipeline.tests-staging.yaml
# pipeline.tests-production.yaml
#
# Docs: https://docs.elastic.dev/serverless/qualitygates

env:
TEAM_CHANNEL: "#kibana-mission-control"
ENVIRONMENT: ${ENVIRONMENT?}

steps:
- label: ":pipeline::grey_question::seedling: Trigger Kibana Tests for ${ENVIRONMENT}"
env:
QG_PIPELINE_LOCATION: ".buildkite/pipelines/quality-gates"
command: "make -C /agent run-environment-tests"
command: "make -C /agent run-environment-tests" # will trigger https://buildkite.com/elastic/kibana-tests
agents:
image: "docker.elastic.co/ci-agent-images/quality-gate-seedling:0.0.2"

notify:
- slack: "${TEAM_CHANNEL?}"
if: build.branch == "main" && build.state == "failed"
25 changes: 12 additions & 13 deletions .buildkite/pipelines/quality-gates/pipeline.tests-production.yaml
Original file line number Diff line number Diff line change
@@ -1,21 +1,20 @@
env:
TEAM_CHANNEL: "#kibana-serverless-release"
ENVIRONMENT: "production"
# These pipeline steps constitute the quality gate for your service within the production
# environment. Incorporate any necessary additional logic to validate the service's integrity.
# A failure in this pipeline build will prevent further progression to the subsequent stage.

steps:
- label: ":pipeline::fleet::seedling: Trigger Observability Kibana Tests for ${ENVIRONMENT}"
command: echo "replace me with Observability specific Kibana tests"
agent:
image: "docker.elastic.co/ci-agent-images/basic-buildkite-agent:1688566364"

- label: ":pipeline::lock::seedling: Trigger Security Kibana Tests for ${ENVIRONMENT}"
command: echo "replace me with Security specific Kibana tests"
agent:
image: "docker.elastic.co/ci-agent-images/basic-buildkite-agent:1688566364"
- label: ":pipeline::rocket::seedling: Trigger control-plane e2e tests"
trigger: "ess-k8s-production-e2e-tests" # https://buildkite.com/elastic/ess-k8s-production-e2e-tests
build:
env:
REGION_ID: aws-us-east-1
NAME_PREFIX: ci_test_kibana-promotion_
message: "${BUILDKITE_MESSAGE} (triggered by pipeline.tests-production.yaml)"

- wait: ~

- label: ":judge::seedling: Trigger Manual Tests Phase"
command: "make -C /agent trigger-manual-verification-phase"
if: build.branch == "main"
agents:
image: "docker.elastic.co/ci-agent-images/manual-verification-agent:0.0.1"
image: "docker.elastic.co/ci-agent-images/manual-verification-agent:0.0.2"
59 changes: 39 additions & 20 deletions .buildkite/pipelines/quality-gates/pipeline.tests-qa.yaml
Original file line number Diff line number Diff line change
@@ -1,31 +1,50 @@
env:
TEAM_CHANNEL: "#kibana-serverless-release"
ENVIRONMENT: "qa"
# These pipeline steps constitute the quality gate for your service within the QA environment.
# Incorporate any necessary additional logic to validate the service's integrity. A failure in
# this pipeline build will prevent further progression to the subsequent stage.

steps:
- label: ":pipeline::kibana::seedling: Trigger Kibana Tests for ${ENVIRONMENT}"
command: echo "replace me with Kibana specific tests"
agent:
image: "docker.elastic.co/ci-agent-images/basic-buildkite-agent:1688566364"
- label: ":pipeline::kibana::seedling: Trigger Kibana Serverless Tests for ${ENVIRONMENT}"
trigger: appex-qa-kibana-serverless-ftr-tests # https://buildkite.com/elastic/appex-qa-kibana-serverless-ftr-tests
soft_fail: true # Remove this before release or when tests stabilize
build:
env:
ENVIRONMENT: ${ENVIRONMENT}
message: "${BUILDKITE_MESSAGE} (triggered by pipeline.tests-qa.yaml)"

- label: ":pipeline::fleet::seedling: Trigger Fleet Kibana Tests for ${ENVIRONMENT}"
command: echo "replace me with Fleet specific Kibana tests"
agent:
image: "docker.elastic.co/ci-agent-images/basic-buildkite-agent:1688566364"
- group: ":female-detective: Security Solution Tests"
key: "security"
steps:
- label: ":pipeline::female-detective::seedling: Trigger Security Solution quality gate script"
command: .buildkite/scripts/pipelines/security_solution_quality_gate/pipeline.sh

- label: ":pipeline::lock::seedling: Trigger Security Kibana Tests for ${ENVIRONMENT}"
command: echo "replace me with Security specific Kibana tests"
agent:
image: "docker.elastic.co/ci-agent-images/basic-buildkite-agent:1688566364"
- label: ":judge::seedling: Trigger Manual Tests Phase"
command: "make -C /agent trigger-manual-verification-phase"
if: build.branch == "main"
env:
TEAM_CHANNEL: "#kibana-mission-control"
agents:
image: "docker.elastic.co/ci-agent-images/manual-verification-agent:0.0.2"

- label: ":pipeline::lock::seedling: Trigger Control Plane Kibana Tests for ${ENVIRONMENT}"
command: echo "replace me with Control Plane specific Kibana tests"
agent:
image: "docker.elastic.co/ci-agent-images/basic-buildkite-agent:1688566364"
- label: ":pipeline::ship::seedling: Trigger Fleet serverless smoke tests for ${ENVIRONMENT}"
trigger: fleet-smoke-tests # https://buildkite.com/elastic/fleet-smoke-tests
soft_fail: true # Remove this before release
build:
env:
ENVIRONMENT: ${ENVIRONMENT}
message: "${BUILDKITE_MESSAGE} (triggered by pipeline.tests-qa.yaml)"

- label: ":pipeline::rocket::seedling: Trigger control-plane e2e tests"
trigger: "ess-k8s-qa-e2e-tests-daily" # https://buildkite.com/elastic/ess-k8s-qa-e2e-tests-daily
build:
env:
REGION_ID: aws-eu-west-1
NAME_PREFIX: ci_test_kibana-promotion_
message: "${BUILDKITE_MESSAGE} (triggered by pipeline.tests-qa.yaml)"

- wait: ~

- label: ":judge::seedling: Trigger Manual Tests Phase"
command: "make -C /agent trigger-manual-verification-phase"
if: build.branch == "main"
agents:
image: "docker.elastic.co/ci-agent-images/manual-verification-agent:0.0.1"
image: "docker.elastic.co/ci-agent-images/manual-verification-agent:0.0.2"
25 changes: 12 additions & 13 deletions .buildkite/pipelines/quality-gates/pipeline.tests-staging.yaml
Original file line number Diff line number Diff line change
@@ -1,21 +1,20 @@
env:
TEAM_CHANNEL: "#kibana-serverless-release"
ENVIRONMENT: "staging"
# These pipeline steps constitute the quality gate for your service within the staging environment.
# Incorporate any necessary additional logic to validate the service's integrity. A failure in
# this pipeline build will prevent further progression to the subsequent stage.

steps:
- label: ":pipeline::fleet::seedling: Trigger Observability Kibana Tests for ${ENVIRONMENT}"
command: echo "replace me with Observability specific Kibana tests"
agent:
image: "docker.elastic.co/ci-agent-images/basic-buildkite-agent:1688566364"

- label: ":pipeline::lock::seedling: Trigger Security Kibana Tests for ${ENVIRONMENT}"
command: echo "replace me with Security specific Kibana tests"
agent:
image: "docker.elastic.co/ci-agent-images/basic-buildkite-agent:1688566364"
- label: ":pipeline::rocket::seedling: Trigger control-plane e2e tests"
trigger: "ess-k8s-staging-e2e-tests" # https://buildkite.com/elastic/ess-k8s-staging-e2e-tests
build:
env:
REGION_ID: aws-us-east-1
NAME_PREFIX: ci_test_kibana-promotion_
message: "${BUILDKITE_MESSAGE} (triggered by pipeline.tests-staging.yaml)"

- wait: ~

- label: ":judge::seedling: Trigger Manual Tests Phase"
command: "make -C /agent trigger-manual-verification-phase"
if: build.branch == "main"
agents:
image: "docker.elastic.co/ci-agent-images/manual-verification-agent:0.0.1"
image: "docker.elastic.co/ci-agent-images/manual-verification-agent:0.0.2"
8 changes: 1 addition & 7 deletions .buildkite/pipelines/serverless.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,13 +105,11 @@ steps:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 40
parallelism: 16
parallelism: 12
retry:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-serverless/**/*"

- command: .buildkite/scripts/steps/functional/security_serverless_explore.sh
label: 'Serverless Explore - Security Solution Cypress Tests'
Expand All @@ -124,8 +122,6 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-serverless/**/*"

- command: .buildkite/scripts/steps/functional/security_serverless_investigations.sh
label: 'Serverless Investigations - Security Solution Cypress Tests'
Expand All @@ -138,5 +134,3 @@ steps:
automatic:
- exit_status: '*'
limit: 1
artifact_paths:
- "target/kibana-security-serverless/**/*"
1 change: 1 addition & 0 deletions .buildkite/scripts/pipelines/pull_request/pipeline.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ const uploadPipeline = (pipelineContent: string | object) => {
) {
pipeline.push(getPipeline('.buildkite/pipelines/pull_request/fleet_cypress.yml'));
pipeline.push(getPipeline('.buildkite/pipelines/pull_request/defend_workflows.yml'));
pipeline.push(getPipeline('.buildkite/pipelines/pull_request/osquery_cypress.yml'));
}

if (
Expand Down
1 change: 1 addition & 0 deletions .buildkite/scripts/steps/functional/defend_workflows.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,5 @@ echo "--- Defend Workflows Cypress tests"

cd x-pack/plugins/security_solution

set +e
yarn cypress:dw:run; status=$?; yarn junit:merge && exit $status
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,5 @@ echo "--- Defend Workflows Endpoint Cypress tests"

cd x-pack/plugins/security_solution

set +e
yarn cypress:dw:endpoint:run; status=$?; yarn junit:merge && exit $status
4 changes: 3 additions & 1 deletion .buildkite/scripts/steps/functional/osquery_cypress.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,6 @@ export JOB=kibana-osquery-cypress

echo "--- Osquery Cypress tests"

yarn --cwd x-pack/plugins/osquery cypress:run
cd x-pack/plugins/osquery

yarn --cwd x-pack/plugins/osquery cypress:run
Loading

0 comments on commit af66475

Please sign in to comment.