vaguerent/.ci/spec/create-packet.sh
2020-09-02 17:02:17 -05:00

23 lines
531 B
Bash
Executable File

#!/usr/bin/env bash
csource="${BASH_SOURCE[0]}"
while [ -h "$csource" ] ; do csource="$(readlink "$csource")"; done
root="$( cd -P "$( dirname "$csource" )/../../" && pwd )"
. "${root}/.ci/common.sh"
. "${root}/.ci/spec/env.sh"
pushd "${root}" > "${output}"
# Ensure we have a packet device to connect
echo "Creating packet device if needed..."
packet-exec info
if [ $? -ne 0 ]; then
wrap_stream packet-exec create \
"Failed to create packet device"
fi
echo "Finished creating spec test packet instance"