Skip to content

Commit

Permalink
Fix VCS errors in daily serverless tests (elastic#3924)
Browse files Browse the repository at this point in the history
* tinker with build issues

* re-add build line

* tinkering with strings

* add env var to build

* try changing workdir

* try to build from beats dir

* add debug statements

* remove level arg to git

* remote commented-out block
  • Loading branch information
fearful-symmetry authored Dec 19, 2023
1 parent dcc6493 commit cc81e4b
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions .buildkite/scripts/steps/beats_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,19 @@ source .buildkite/scripts/common.sh
STACK_PROVISIONER="${1:-"serverless"}"

run_test_for_beat(){
export GOFLAGS='-buildvcs=false'
local beat_name=$1

#build
export WORKSPACE="build/beats/x-pack/${beat_name}"
export WORKSPACE="/tmp/beats-build/beats/x-pack/${beat_name}"
pushd $WORKSPACE
whoami
ls -la
SNAPSHOT=true PLATFORMS=linux/amd64 PACKAGES=tar.gz,zip mage package
popd

#run
export AGENT_BUILD_DIR="build/beats/x-pack/${beat_name}/build/distributions"
export AGENT_BUILD_DIR="/tmp/beats-build/beats/x-pack/${beat_name}/build/distributions"
export WORKSPACE=$(pwd)

set +e
Expand All @@ -33,11 +38,13 @@ run_test_for_beat(){
#the setup scripts will do a few things that assume we're running out of elastic-agent and will break things for beats, so run before we do actual setup
mage -l

mkdir -p build
cd build
# mkdir -p build
# cd build
mkdir -p /tmp/beats-build
pushd /tmp/beats-build

git clone --filter=tree:0 [email protected]:elastic/beats.git
cd ..
git clone [email protected]:elastic/beats.git
popd

# export WORKSPACE=beats/x-pack/metricbeat

Expand Down

0 comments on commit cc81e4b

Please sign in to comment.