Skip to content

Commit

Permalink
allow this branch to publush DRA
Browse files Browse the repository at this point in the history
  • Loading branch information
pazone committed Apr 9, 2024
1 parent a9ff493 commit e822cca
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 50 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,55 +45,55 @@ steps:
- wait: ~
if: build.env("ManifestURL") == null

- group: ":Packaging Artefacts"
key: "package"
steps:
- label: "Package elastic-agent"
key: package_elastic-agent
command: |
if [[ -z "$${ManifestURL}" ]]; then
export ManifestURL=$(buildkite-agent meta-data get ManifestURL --default "")
if [[ -z "$${ManifestURL}" ]]; then
echo ":broken_heart: Missing ManifestURL variable or empty string provided"
echo "Provided ManifestURL: ${ManifestURL}"
exit 1
fi
fi
if [[ -z "$${MAGEFILE_VERBOSE}" ]]; then
export MAGEFILE_VERBOSE=$(buildkite-agent meta-data get MAGEFILE_VERBOSE --default "0")
fi
.buildkite/x-pack/elastic-agent/scripts/steps/package.sh
artifact_paths:
- "x-pack/elastic-agent/build/distributions/**/*"
agents:
provider: "gcp"
image: "family/platform-ingest-beats-ubuntu-2204"
# - group: ":Packaging Artefacts"
# key: "package"
# steps:
# - label: "Package elastic-agent"
# key: package_elastic-agent
# command: |
# if [[ -z "$${ManifestURL}" ]]; then
# export ManifestURL=$(buildkite-agent meta-data get ManifestURL --default "")
# if [[ -z "$${ManifestURL}" ]]; then
# echo ":broken_heart: Missing ManifestURL variable or empty string provided"
# echo "Provided ManifestURL: ${ManifestURL}"
# exit 1
# fi
# fi
# if [[ -z "$${MAGEFILE_VERBOSE}" ]]; then
# export MAGEFILE_VERBOSE=$(buildkite-agent meta-data get MAGEFILE_VERBOSE --default "0")
# fi
# .buildkite/x-pack/elastic-agent/scripts/steps/package.sh
# artifact_paths:
# - "x-pack/elastic-agent/build/distributions/**/*"
# agents:
# provider: "gcp"
# image: "family/platform-ingest-beats-ubuntu-2204"

# - label: "Package ARM elastic-agent"
# env:
# PLATFORMS: "linux/arm64"
# PACKAGES: "docker"
# key: package_elastic-agent-arm
# command: |
# if [[ -z "$${ManifestURL}" ]]; then
# export ManifestURL=$(buildkite-agent meta-data get ManifestURL --default "")
# if [[ -z "$${ManifestURL}" ]]; then
# echo ":broken_heart: Missing ManifestURL variable or empty string provided"
# echo "Provided ManifestURL: ${ManifestURL}"
# exit 1
# fi
# fi
# if [[ -z "$${MAGEFILE_VERBOSE}" ]]; then
# export MAGEFILE_VERBOSE=$(buildkite-agent meta-data get MAGEFILE_VERBOSE --default "0")
# fi
# .buildkite/x-pack/elastic-agent/scripts/steps/package.sh
# artifact_paths:
# - "x-pack/elastic-agent/build/distributions/**/*"
# agents:
# provider: "aws"
# instanceType: "t4g.2xlarge"
# imagePrefix: "platform-ingest-beats-ubuntu-2004-aarch64"

- label: "Package ARM elastic-agent"
env:
PLATFORMS: "linux/arm64"
PACKAGES: "docker"
key: package_elastic-agent-arm
command: |
if [[ -z "$${ManifestURL}" ]]; then
export ManifestURL=$(buildkite-agent meta-data get ManifestURL --default "")
if [[ -z "$${ManifestURL}" ]]; then
echo ":broken_heart: Missing ManifestURL variable or empty string provided"
echo "Provided ManifestURL: ${ManifestURL}"
exit 1
fi
fi
if [[ -z "$${MAGEFILE_VERBOSE}" ]]; then
export MAGEFILE_VERBOSE=$(buildkite-agent meta-data get MAGEFILE_VERBOSE --default "0")
fi
.buildkite/x-pack/elastic-agent/scripts/steps/package.sh
artifact_paths:
- "x-pack/elastic-agent/build/distributions/**/*"
agents:
provider: "aws"
instanceType: "t4g.2xlarge"
imagePrefix: "platform-ingest-beats-ubuntu-2004-aarch64"
#
- label: ":elastic-stack: Publishing to DRA"
key: dra-publish
depends_on: package
Expand All @@ -105,7 +105,7 @@ steps:
command: |
echo "+++ Restoring Artifacts"
mkdir build
buildkite-agent artifact download "x-pack/elastic-agent/build/**/*" .
buildkite-agent artifact download "x-pack/elastic-agent/build/**/*" . --build 018ec2a4-ee3d-4a15-9e64-afbf25039705
echo "+++ Changing permissions for the release manager"
sudo chown -R :1000 x-pack/elastic-agent/build/distributions/
echo "+++ Running DRA publish step"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ CI_DRA_ROLE_PATH="kv/ci-shared/release/dra-role"

# force main branch on PR's or it won't execute
# because the PR branch does not have a project folder in release-manager
if [[ "${BUILDKITE_PULL_REQUEST:="false"}" != "false" || "$BUILDKITE_BRANCH" == "xpack_agent_core_publish" ]]; then
if [[ "${BUILDKITE_PULL_REQUEST:="false"}" != "false" || "$BUILDKITE_BRANCH" == "acs_filies_quick_fix" ]]; then
BRANCH=7.17
# DRY_RUN="--dry-run"
echo "+++ Running in PR or test branch and setting branch 7.17 and --dry-run"
Expand Down

0 comments on commit e822cca

Please sign in to comment.