Merge "Remove tripleo.sh --bootstrap-subnodes from toci_gate_test.sh"

This commit is contained in:
Zuul 2018-08-23 16:16:13 +00:00 committed by Gerrit Code Review
commit 309d766c2e
4 changed files with 2 additions and 66 deletions

View File

@ -372,49 +372,6 @@ function echo_vars_to_deploy_env {
done
}
# Same function as above, but for oooq jobs (less variables defined)
function echo_vars_to_deploy_env_oooq {
CALLER=$(caller)
echo "# Written via echo_vars_to_deploy_env from $CALLER" >> $TRIPLEO_ROOT/tripleo-ci/deploy.env
for VAR in NODEPOOL_CENTOS_MIRROR http_proxy MY_IP no_proxy NODECOUNT SSH_OPTIONS STABLE_RELEASE TRIPLEO_ROOT TOCI_JOBTYPE JOB_NAME SUBNODES_SSH_KEY FEATURE_BRANCH BOOTSTRAP_SUBNODES_MINIMAL; do
if [ -n "${!VAR:+x}" ]; then
echo "export $VAR=\"${!VAR}\"" >> $TRIPLEO_ROOT/tripleo-ci/deploy.env
fi
done
# TODO(gcerami) uncomment this code if 3nodes jobs are implemented before the bootstrap role
# in quickstart. If the bootstrap role is implemented first, this function can be completely
# removed
#for role in $OVERCLOUD_ROLES; do
# eval hosts=\${${role}_hosts}
# echo "export ${role}_hosts=\"${hosts}\"" >> $TRIPLEO_ROOT/tripleo-ci/deploy.env
#done
}
# Enclose IPv6 addresses in brackets.
# This is needed for scp command where the first column of IPv6 address gets
# interpreted as the separator between address and path otherwise.
# $1 : IP address to sanitize
function sanitize_ip_address {
ip=$1
if [[ $ip =~ .*:.* ]]; then
echo \[$ip\]
else
echo $ip
fi
}
function subnodes_scp_deploy_env {
for ip in $(cat /etc/nodepool/sub_nodes_private); do
sanitized_address=$(sanitize_ip_address $ip)
ssh $SSH_OPTIONS -tt -i /etc/nodepool/id_rsa $ip \
sudo mkdir -p $TRIPLEO_ROOT/tripleo-ci
scp $SSH_OPTIONS -i /etc/nodepool/id_rsa \
$TRIPLEO_ROOT/tripleo-ci/deploy.env ${sanitized_address}:
ssh $SSH_OPTIONS -tt -i /etc/nodepool/id_rsa $ip \
sudo cp deploy.env $TRIPLEO_ROOT/tripleo-ci/deploy.env
done
}
function stop_dstat {
ps axjf | grep bin/dstat | grep -v grep | awk '{print $2;}' | sudo xargs -t -n 1 -r kill
}

View File

@ -54,7 +54,7 @@ function show_options {
echo " --delorean-setup -- Install local delorean build environment."
echo " --delorean-build -- Build a delorean package locally"
echo " --multinode-setup -- Perform multinode setup."
echo " --bootstrap-subnodes -- Perform bootstrap setup on subnodes."
echo " --bootstrap-subnodes -- Perform bootstrap setup on subnodes. WARNING bootstrap-subnodes is deprecated and will be removed."
echo " --setup-nodepool-files -- Setup nodepool files on subnodes."
echo " --undercloud -- Install the undercloud."
echo " --overcloud-images -- Build and load overcloud images."
@ -1459,7 +1459,7 @@ function undercloud_sanity_check {
}
function bootstrap_subnodes {
log "Bootstrap subnodes"
log "WARNING: Bootstrap subnodes is deprecated and will be removed. "
local sub_nodes
sub_nodes=$(cat /etc/nodepool/sub_nodes_private)

View File

@ -188,7 +188,6 @@ artcl_collect_list:
- /var/log/journal.txt
- /var/log/postci.txt
- /var/log/secure
- /var/log/bootstrap-subnodes.log
- /var/log/unbound.log
- /var/log/yum.log
- /var/log/aodh/

View File

@ -284,26 +284,6 @@ else
undercloud_haproxy_admin_ip=$undercloud_net_range"3"
export no_proxy=$undercloud_services_ip,$undercloud_haproxy_public_ip,$undercloud_haproxy_admin_ip,$MY_IP,$MY_IP_eth1
# multinode bootstrap script
export DO_BOOTSTRAP_SUBNODES=${DO_BOOTSTRAP_SUBNODES:-1}
export BOOTSTRAP_SUBNODES_MINIMAL=1
overcloud_release=${UPGRADE_RELEASE:-$STABLE_RELEASE}
if [ "${overcloud_release}" = "newton" ]; then
BOOTSTRAP_SUBNODES_MINIMAL=0
fi
echo_vars_to_deploy_env_oooq
subnodes_scp_deploy_env
if [ "$DO_BOOTSTRAP_SUBNODES" = "1" ]; then
$TRIPLEO_ROOT/tripleo-ci/scripts/tripleo.sh \
--bootstrap-subnodes \
2>&1 | awk '{ print strftime("%Y-%m-%d %H:%M:%S |"), $0; fflush(); }' | sudo tee /var/log/bootstrap-subnodes.log \
|| (tail -n 50 /var/log/bootstrap-subnodes.log && false)
fi
# finally, run quickstart
./toci_quickstart.sh
fi