Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion build-scripts/unpack-tarballs
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,5 @@ log_debug "UNPACKING MASTERFILES TARBALL: $MASTERFILES_TARBALL AND SYMLINKING ma
# We want globbing here
gzip -dc $MASTERFILES_TARBALL | tar -xf -
# the masterfiles tarball would match cfengine-masterfiles-* so find the unpacked dir specifically
_cfmpfdir=$(find -type d -name 'cfengine-masterfiles-*')
_cfmpfdir=$(find . -type d -name 'cfengine-masterfiles-*')
ln -s "$_cfmpfdir" masterfiles
11 changes: 8 additions & 3 deletions ci/fix-buildhost.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,18 @@
#!/usr/bin/env bash
# it is expected that this file is sourced, not executed directly
set -ex
my_path="$(realpath "${BASH_SOURCE[0]}")"
my_dir="$(dirname "$my_path")"

if [ -f /etc/os-release ]; then
source /etc/os-release
if [ "$ID" = "centos" ] && [ "$VERSION_ID" = "7" ]; then
source "$my_dir"/centos-7-setup-devtoolset-11.sh
if command -v realpath >/dev/null; then
my_path="$(realpath "${BASH_SOURCE[0]}")"
my_dir="$(dirname "$my_path")"
source "$my_dir"/centos-7-setup-devtoolset-11.sh
else
echo "FAIL: could not find realpath command on rhel/centos-7 to source needed centos-7-setup-devtoolset-11.sh"
exit 1
fi
fi
fi

Expand Down
10 changes: 5 additions & 5 deletions ci/initialize-build-host.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# serial execution of initialization steps. It will post the output when
# finished, if any.
#
# 2. If $(pwd)/proxy-target.txt exists, it means this is a proxy host, and the
# 2. If $HOME/proxy-target.txt exists, it means this is a proxy host, and the
# real build machine is on the host specified by the login details inside
# that file. If the file does not exist, we are on the build slave itself.
# After figuring that stuff out, the script will run the rest of the original
Expand Down Expand Up @@ -227,15 +227,15 @@ reset_nested_vm() {
fi
if [ ! -z "$login" ]
then
ip=`sed 's/.*@//' $(pwd)/proxy-target.txt`
ip=`sed 's/.*@//' $HOME/proxy-target.txt`
if sudo arp | grep -q $ip
then
sudo arp -d $ip
fi
fi
# TODO, remove this, we don't need or use or test nested-vms
$HOME/mender-qa/scripts/nested-vm.sh $HOME/*.qcow2
login="`cat $(pwd)/proxy-target.txt`"
login="`cat $HOME/proxy-target.txt`"
if $RSH $login true
then
echo "Nested VM is back up, it seems. Happily continuing!"
Expand Down Expand Up @@ -277,13 +277,13 @@ reset_nested_vm() {
fi
}

if [ -f $(pwd)/proxy-target.txt ]
if [ -f $HOME/proxy-target.txt ]
then
# --------------------------------------------------------------------------
# Check target machine health.
# --------------------------------------------------------------------------

login="$(cat $(pwd)/proxy-target.txt)"
login="$(cat $HOME/proxy-target.txt)"

if [ ! -z "$login" ] && $RSH $login true
then
Expand Down
Loading