Skip to content

Commit

Permalink
updated pipeline and scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
oakrizan committed Apr 30, 2024
1 parent 51d2597 commit 8a7b899
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .buildkite/pipeline.yml
Expand Up @@ -139,7 +139,7 @@ steps:
commit: "${BUILDKITE_COMMIT}"
branch: "${BUILDKITE_BRANCH}"

- label: "Trigger Xpack/Dockerlogbeat"
- label: "Trigger x-pack/dockerlogbeat"
if: build.pull_request.id != null
plugins:
- monorepo-diff#v1.0.1:
Expand Down
5 changes: 0 additions & 5 deletions .buildkite/scripts/common.sh
Expand Up @@ -24,11 +24,6 @@ XPACK_MODULE_PATTERN="^x-pack\\/[a-z0-9]+beat\\/module\\/([^\\/]+)\\/.*"
# define if needed run cloud-specific tests for the particular beat
[ -z "${run_xpack_metricbeat_aws_tests+x}" ] && run_xpack_metricbeat_aws_tests="$(buildkite-agent meta-data get run_xpack_metricbeat_aws_tests --default "false")"


xpack_dockerlogbeat_changeset=(
"^x-pack/dockerlogbeat/.*"
)

ci_changeset=(
"^.buildkite/.*"
)
Expand Down
2 changes: 1 addition & 1 deletion .buildkite/scripts/setenv.sh
Expand Up @@ -49,7 +49,7 @@ if [[ "$BUILDKITE_PIPELINE_SLUG" == "beats-metricbeat" || "$BUILDKITE_PIPELINE_S
export TEST_TAGS="${TEST_TAGS:+$TEST_TAGS,}oracle"
fi

if [[ "$BUILDKITE_STEP_KEY" == "xpack-winlogbeat-pipeline" || "$BUILDKITE_STEP_KEY" == "xpack-metricbeat-pipeline" || "$BUILDKITE_STEP_KEY" == "xpack-dockerlogbeat-pipeline" || "$BUILDKITE_STEP_KEY" == "metricbeat-pipeline" ]]; then
if [[ "$BUILDKITE_STEP_KEY" == "xpack-winlogbeat-pipeline" || "$BUILDKITE_STEP_KEY" == "xpack-metricbeat-pipeline" || "$BUILDKITE_STEP_KEY" == "metricbeat-pipeline" ]]; then
source .buildkite/scripts/common.sh
# Set the MODULE env variable if possible, it should be defined before generating pipeline's steps. It is used in multiple pipelines.
defineModuleFromTheChangeSet "${BEATS_PROJECT_NAME}"
Expand Down
26 changes: 16 additions & 10 deletions .buildkite/x-pack/pipeline.xpack.dockerlogbeat.yml
@@ -1,5 +1,5 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/buildkite/pipeline-schema/main/schema.json
name: "beats-xpack-dockerlogbeat"
name: "beats-x-pack-dockerlogbeat"

env:
ASDF_MAGE_VERSION: 1.15.0
Expand All @@ -22,10 +22,10 @@ env:
IMAGE_WIN_2022: "family/platform-ingest-beats-windows-2022"

steps:
- group: "Xpack/Dockerlogbeat Mandatory Tests"
key: "xpack-dockerlogbeat-mandatory-tests"
- group: "x-pack/Dockerlogbeat Mandatory Tests"
key: "x-pack-dockerlogbeat-mandatory-tests"
steps:
- label: ":ubuntu: Xpack/Dockerlogbeat Ubuntu Unit Tests"
- label: ":ubuntu: x-pack/Dockerlogbeat Ubuntu Unit Tests"
key: "mandatory-linux-unit-test"
command: "cd x-pack/dockerlogbeat && mage build unitTest"
agents:
Expand All @@ -39,7 +39,7 @@ steps:
- github_commit_status:
context: "x-pack/dockerlogbeat: Ubuntu Unit Tests"

- label: ":ubuntu: Xpack/Dockerlogbeat Go Integration Tests"
- label: ":ubuntu: x-pack/Dockerlogbeat Go Integration Tests"
key: "mandatory-int-test"
command: |
set -euo pipefail
Expand Down Expand Up @@ -68,13 +68,13 @@ steps:
# this allows building DRA artifacts even if there is flakiness in mandatory tests
if: build.env("BUILDKITE_PULL_REQUEST") != "false"
depends_on:
- "xpack-dockerlogbeat-mandatory-tests"
- "x-pack-dockerlogbeat-mandatory-tests"

- group: "Xpack/Dockerlogbeat Packaging"
key: "xpack-dockerlogbeat-packaging"
- group: "x-pack/Dockerlogbeat Packaging"
key: "x-pack-dockerlogbeat-packaging"

steps:
- label: ":ubuntu: Xpack/Dockerlogbeat Packaging Linux X86"
- label: ":ubuntu: x-pack/Dockerlogbeat Packaging Linux X86"
key: "auditbeat-package-linux-x86"
env:
PLATFORMS: "+all linux/amd64 linux/arm64 windows/amd64 darwin/amd64 darwin/arm64"
Expand All @@ -84,8 +84,11 @@ steps:
provider: gcp
image: "${IMAGE_UBUNTU_X86_64}"
machineType: "${GCP_HI_PERF_MACHINE_TYPE}"
notify:
- github_commit_status:
context: "x-pack/dockerlogbeat: Packaging Linux X86"

- label: ":linux: Xpack/Dockerlogbeat Packaging Linux ARM"
- label: ":linux: x-pack/Dockerlogbeat Packaging Linux ARM"
key: "auditbeat-package-linux-arm"
env:
PLATFORMS: "linux/arm64"
Expand All @@ -96,3 +99,6 @@ steps:
provider: "aws"
imagePrefix: "${AWS_IMAGE_UBUNTU_ARM_64}"
instanceType: "${AWS_ARM_INSTANCE_TYPE}"
notify:
- github_commit_status:
context: "x-pack/dockerlogbeat: Packaging Linux ARM"

0 comments on commit 8a7b899

Please sign in to comment.