Skip to content

Commit 554bea1

Browse files
committed
Add TEST_SW_RAID option
This can config software RAID for nodes. Signed-off-by: Hu Shuai <[email protected]>
1 parent 4befdca commit 554bea1

File tree

3 files changed

+15
-0
lines changed

3 files changed

+15
-0
lines changed

common.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -379,3 +379,6 @@ export TEST_CUSTOM_MAO=${TEST_CUSTOM_MAO:-false}
379379
# Set to configure bootstrap VM baremetal network with static IP
380380
# (Currently this just expects a non-empty value, the IP is fixed to .9)
381381
export ENABLE_BOOTSTRAP_STATIC_IP=${ENABLE_BOOTSTRAP_STATIC_IP:-}
382+
383+
# Defaults the variable to disable testing software RAID
384+
export TEST_SW_RAID=${TEST_SW_RAID:-false}

config_example.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -608,3 +608,7 @@ set -x
608608
# cpu and ip stack.
609609
# This config variable is used only by the agent based installer and is required.
610610
# export AGENT_E2E_TEST_SCENARIO=HA_IPV4
611+
612+
# TEST_SW_RAID -
613+
# Enable testing of software RAID
614+
# export TEST_SW_RAID=true

utils.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,14 @@ function create_cluster() {
108108
mkdir -p ${assets_dir}/openshift
109109
generate_assets
110110

111+
if [[ "$TEST_SW_RAID" == "true" ]]; then
112+
sed -i "/status/i \\
113+
raid: \n\
114+
softwareRAIDVolumes: \n\
115+
- level: \"1\" \
116+
" ${assets_dir}/openshift/99_openshift-cluster-api_hosts-*.yaml
117+
fi
118+
111119
if [ -z "${NTP_SERVERS}" ];
112120
then
113121
export NTP_SERVERS="$PROVISIONING_HOST_EXTERNAL_IP"

0 commit comments

Comments
 (0)