forked from liza-mae/elastic-stack-testing
-
Notifications
You must be signed in to change notification settings - Fork 0
/
buildenv.sh
executable file
·54 lines (42 loc) · 1.64 KB
/
buildenv.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#!/bin/bash
#
# @author: Liza Dayoub
#-- Run locally
export AIT_RUN_LOCAL=true
#-- Provider type: vagrant, gcp, aws
export AIT_PROVIDER=${AIT_PROVIDER:-vagrant}
#-- Build URL
# Accepted formats: artifacts.elastic.co/8.0.1, snapshots.elastic.co/8.2.0-234fa56
# staging.elastic.co/8.1.1-2346753a
export ES_BUILD_URL=${ES_BUILD_URL:-}
#-- Playbook
# Playbooks are in the playbooks directory, full path does not need to specified
export AIT_ANSIBLE_PLAYBOOK=${AIT_ANSIBLE_PLAYBOOK:-get_started/install_elk}
#-- Machine Architecture
# The default machine architecture is x86_64
# export ES_BUILD_ARCH=arm64
#-- Build Type
# Build oss version, false is only option for recent builds
export ES_BUILD_OSS=false
#-- Build package extension
# Build extension, only tar is currently available
export ES_BUILD_PKG_EXT=tar
if [ "$AIT_PROVIDER" == "vagrant" ]; then
#-- Vagrant Provider
# The default vagrant provider is virtualbox.
# Virtualbox is not supported on arm
# If running on arm, also set ES_BUILD_ARCH
# export VAGRANT_DEFAULT_PROVIDER=docker
#-- Setup new VM
# When AIT_HOST_INVENTORY_DIR is set, this will be skipped
export AIT_VM=vagrant_vm
#-- Reuse an existing VM
# This will resuse the same VM to rerun playbook. Find the instance you
# want to use by doing an ls in the ait_workspace directory. The name of
# the directory will be will be in format: 8-0-1_os which is set below
export AIT_HOST_INVENTORY_DIR=${AIT_HOST_INVENTORY_DIR:-}
#-- Skip destroying the VM
# When set to false, it will shutdown the VM, if set to true it remains running
export AIT_SKIP_VM_CLEANUP=true
fi
source ci_build.sh