diskimage-builder/diskimage_builder/elements/openstack-ci-mirrors/extra-data.d/75-copy-mirror-info
Ian Wienand 8b0111477e Set EPEL mirror during openstack-ci-mirrors
We want to set DIB_EPEL_MIRROR for the epel element, which means we
need access to the CI mirror info script in the chroot.  Copy it into
the temp directory with extra-data.d and update the environment file
to find it.

Change-Id: Ia12f0cbdeb194eef3155497ceb5ffc4a452aad76
2018-10-18 13:53:53 +11:00

18 lines
372 B
Bash
Executable File

#!/bin/bash
if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
set -x
fi
set -eu
set -o pipefail
# On infra nodes, make a copy of the mirror_info.sh script inside the
# chroot for elements running in chroot like EPEL that want to
# reference it.
mirror_info=/etc/ci/mirror_info.sh
if [ -f $mirror_info ]; then
cp /etc/ci/mirror_info.sh $TMP_HOOKS_PATH/mirror_info.sh
fi