Skip to content

Commit

Permalink
add-triggers
Browse files Browse the repository at this point in the history
  • Loading branch information
Siarhei Harbuz committed Feb 13, 2024
1 parent c7aa93e commit c5881a2
Show file tree
Hide file tree
Showing 9 changed files with 150 additions and 3 deletions.
4 changes: 4 additions & 0 deletions .buildkite/libbeat/pipeline.libbeat.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/buildkite/pipeline-schema/main/schema.json
name: "beats-libbeat"

env:
IMAGE_UBUNTU_X86_64: "family/core-ubuntu-2204"
Expand Down Expand Up @@ -39,3 +40,6 @@ steps:
- label: ":linux: Load dynamic Libbeat pipeline"
key: "libbeat-pipeline"
command: ".buildkite/scripts/generate_libbeat_pipeline.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Load dynamic pipeline"
5 changes: 5 additions & 0 deletions .buildkite/metricbeat/pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/buildkite/pipeline-schema/main/schema.json
name: "beats-metricbeat"

env:
IMAGE_UBUNTU_X86_64: "family/core-ubuntu-2204"
IMAGE_UBUNTU_ARM_64: "core-ubuntu-2004-aarch64"
Expand Down Expand Up @@ -45,3 +47,6 @@ steps:
- label: ":linux: Load dynamic metricbeat pipeline"
key: "metricbeat-pipeline"
command: ".buildkite/scripts/generate_metricbeat_pipeline.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Load dynamic pipeline"
5 changes: 5 additions & 0 deletions .buildkite/packetbeat/pipeline.packetbeat.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/buildkite/pipeline-schema/main/schema.json
name: "beats-packetbeat"

env:
IMAGE_UBUNTU_X86_64: "family/core-ubuntu-2204"
IMAGE_UBUNTU_ARM_64: "core-ubuntu-2004-aarch64"
Expand Down Expand Up @@ -53,3 +55,6 @@ steps:
- label: ":linux: Load dynamic packetbeat pipeline"
key: "packetbeat-pipeline"
command: ".buildkite/scripts/generate_packetbeat_pipeline.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Load dynamic pipeline"
37 changes: 35 additions & 2 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,38 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/buildkite/pipeline-schema/main/schema.json

steps:
- label: "Example test"
command: echo "Hello!"
- trigger: "beats-packetbeat"
label: ":esbuild: Downstream - beats-packetbeat"
key: "downstream-beats-packetbeat"
async: true
build:
env:
BUILDKITE_REFSPEC: "refs/pull/${BUILDKITE_PULL_REQUEST}/head"
BUILDKITE_COMMIT: "${BUILDKITE_COMMIT}"

- trigger: "beats-libbeat"
label: ":esbuild: Downstream - beats-libbeat"
key: "downstream-beats-libbeat"
async: true
build:
env:
BUILDKITE_REFSPEC: "refs/pull/${BUILDKITE_PULL_REQUEST}/head"
BUILDKITE_COMMIT: "${BUILDKITE_COMMIT}"

- trigger: "beats-metricbeat"
label: ":esbuild: Downstream - beats-metricbeat"
key: "downstream-beats-metricbeat"
async: true
build:
env:
BUILDKITE_REFSPEC: "refs/pull/${BUILDKITE_PULL_REQUEST}/head"
BUILDKITE_COMMIT: "${BUILDKITE_COMMIT}"

- trigger: "beats-winlogbeat"
label: ":esbuild: Downstream - beats-winlogbeat"
key: "downstream-beats-winlogbeat"
async: true
build:
env:
BUILDKITE_REFSPEC: "refs/pull/${BUILDKITE_PULL_REQUEST}/head"
BUILDKITE_COMMIT: "${BUILDKITE_COMMIT}"
18 changes: 18 additions & 0 deletions .buildkite/scripts/generate_libbeat_pipeline.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ steps:
- label: ":linux: Ubuntu Unit Tests"
key: "mandatory-linux-unit-test"
command: ".buildkite/scripts/unit_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Ubuntu Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -27,6 +30,9 @@ steps:
- label: ":go: Go Integration Tests"
key: "mandatory-int-test"
command: ".buildkite/scripts/go_int_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Go Integration Tests"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -36,6 +42,9 @@ steps:
- label: ":python: Python Integration Tests"
key: "mandatory-python-int-test"
command: ".buildkite/scripts/py_int_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Python Integration Tests"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -45,6 +54,9 @@ steps:
- label: ":negative_squared_cross_mark: Cross compile"
key: "mandatory-cross-compile"
command: ".buildkite/scripts/crosscompile.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Cross compile"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -54,6 +66,9 @@ steps:
- label: ":testengine: Stress Tests"
key: "mandatory-stress-test"
command: ".buildkite/scripts/stress_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Stress Tests"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -76,6 +91,9 @@ if are_conditions_met_arm_tests; then
- label: ":linux: Arm64 Unit Tests"
key: "extended-arm64-unit-tests"
command: ".buildkite/scripts/unit_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Arm64 Unit Tests"
agents:
provider: "aws"
imagePrefix: "${IMAGE_UBUNTU_ARM_64}"
Expand Down
34 changes: 33 additions & 1 deletion .buildkite/scripts/generate_metricbeat_pipeline.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ steps:
- label: ":linux: Ubuntu Unit Tests"
key: "mandatory-linux-unit-test"
command: ".buildkite/scripts/unit_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Ubuntu Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -27,6 +30,9 @@ steps:
- label: ":go: Go Intergration Tests"
key: "mandatory-int-test"
command: ".buildkite/scripts/go_int_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Go Intergration Tests"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -36,6 +42,9 @@ steps:
- label: ":python: Python Integration Tests"
key: "mandatory-python-int-test"
command: ".buildkite/scripts/py_int_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Python Integration Tests"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -45,6 +54,9 @@ steps:
- label: ":negative_squared_cross_mark: Cross compile"
key: "mandatory-cross-compile"
command: ".buildkite/scripts/crosscompile.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Cross compile"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -53,6 +65,9 @@ steps:
- label: ":windows: Windows 2016/2022 Unit Tests - {{matrix.image}}"
command: ".buildkite/scripts/win_unit_tests.ps1"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Windows 2016/2022 Unit Tests"
key: "mandatory-win-unit-tests"
agents:
provider: "gcp"
Expand All @@ -76,6 +91,9 @@ steps:
- label: ":windows: Windows 2019 Unit Tests"
key: "extended-win-2019-unit-tests"
command: ".buildkite/scripts/win_unit_tests.ps1"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Windows 2019 Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_WIN_2019}"
Expand All @@ -84,10 +102,12 @@ steps:
disk_type: "pd-ssd"
artifact_paths: "${BEATS_PROJECT_NAME}/build/*.*"
# Temporary disabled https://github.com/elastic/beats/issues/37841
- label: ":windows: Windows 10 Unit Tests"
key: "extended-win-10-unit-tests"
command: ".buildkite/scripts/win_unit_tests.ps1"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Windows 10 Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_WIN_10}"
Expand All @@ -99,6 +119,9 @@ steps:
- label: ":windows: Windows 11 Unit Tests"
key: "extended-win-11-unit-tests"
command: ".buildkite/scripts/win_unit_tests.ps1"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Windows 11 Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_WIN_11}"
Expand All @@ -122,6 +145,9 @@ if are_conditions_met_macos_tests; then
- label: ":mac: MacOS Unit Tests"
key: "extended-macos-unit-tests"
command: ".buildkite/scripts/unit_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: MacOS Unit Tests"
agents:
provider: "orka"
imagePrefix: "${IMAGE_MACOS_X86_64}"
Expand All @@ -145,6 +171,9 @@ if are_conditions_met_packaging; then
- label: ":linux: Packaging Linux"
key: "packaging-linux"
command: ".buildkite/scripts/packaging.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Packaging Linux"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -155,6 +184,9 @@ if are_conditions_met_packaging; then
- label: ":linux: Packaging ARM"
key: "packaging-arm"
command: ".buildkite/scripts/packaging.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Packaging ARM"
agents:
provider: "aws"
imagePrefix: "${IMAGE_UBUNTU_ARM_64}"
Expand Down
30 changes: 30 additions & 0 deletions .buildkite/scripts/generate_packetbeat_pipeline.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ steps:
- label: ":linux: Ubuntu Unit Tests"
key: "mandatory-linux-unit-test"
command: ".buildkite/scripts/unit_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Ubuntu Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -27,6 +30,9 @@ steps:
- label: ":rhel: RHEL-9 Unit Tests"
key: "mandatory-rhel9-unit-test"
command: ".buildkite/scripts/unit_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: RHEL-9 Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_RHEL9_X86_64}"
Expand All @@ -37,6 +43,9 @@ steps:
- label: ":windows: Windows Unit Tests - {{matrix.image}}"
command: ".buildkite/scripts/win_unit_tests.ps1"
key: "mandatory-win-unit-tests"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Windows Unit Tests"
agents:
provider: "gcp"
image: "{{matrix.image}}"
Expand All @@ -56,6 +65,9 @@ steps:
- label: ":windows: Win 2019 Unit Tests"
key: "extended-win-2019-unit-tests"
command: ".buildkite/scripts/win_unit_tests.ps1"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Win 2019 Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_WIN_2019}"
Expand All @@ -67,6 +79,9 @@ steps:
- label: ":windows: Windows 10 Unit Tests"
key: "extended-win-10-unit-tests"
command: ".buildkite/scripts/win_unit_tests.ps1"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Windows 10 Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_WIN_10}"
Expand All @@ -78,6 +93,9 @@ steps:
- label: ":windows: Windows 11 Unit Tests"
key: "extended-win-11-unit-tests"
command: ".buildkite/scripts/win_unit_tests.ps1"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Windows 11 Unit Tests"
agents:
provider: "gcp"
image: "${IMAGE_WIN_11}"
Expand Down Expand Up @@ -108,6 +126,9 @@ if are_conditions_met_macos_tests; then
- label: ":mac: MacOS Unit Tests"
key: "extended-macos-unit-tests"
command: ".buildkite/scripts/unit_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: MacOS Unit Tests"
agents:
provider: "orka"
imagePrefix: "${IMAGE_MACOS_X86_64}"
Expand All @@ -121,6 +142,9 @@ if are_conditions_met_arm_tests; then
- label: ":linux: ARM Ubuntu Unit Tests"
key: "extended-arm64-unit-test"
command: ".buildkite/scripts/unit_tests.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: ARM Ubuntu Unit Tests"
agents:
provider: "aws"
imagePrefix: "${IMAGE_UBUNTU_ARM_64}"
Expand All @@ -145,6 +169,9 @@ if are_conditions_met_packaging; then
- label: ":linux: Packaging Linux"
key: "packaging-linux"
command: ".buildkite/scripts/packaging.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Packaging Linux"
agents:
provider: "gcp"
image: "${IMAGE_UBUNTU_X86_64}"
Expand All @@ -155,6 +182,9 @@ if are_conditions_met_packaging; then
- label: ":linux: Packaging ARM"
key: "packaging-arm"
command: ".buildkite/scripts/packaging.sh"
notify:
- github_commit_status:
context: "${BEATS_PROJECT_NAME}: Packaging ARM"
agents:
provider: "aws"
imagePrefix: "${IMAGE_UBUNTU_ARM_64}"
Expand Down

0 comments on commit c5881a2

Please sign in to comment.