mirror of https://github.com/status-im/consul.git
Envoy integration test improvements (#5797)
* Grab consul logs on integration test failures too and don't remove .gitignore * Don't wipe logs so we have some artifacts to upload at the end
This commit is contained in:
parent
f452de1c50
commit
2d47b28722
|
@ -83,7 +83,10 @@ for c in ./case-*/ ; do
|
||||||
|
|
||||||
# Wipe state
|
# Wipe state
|
||||||
docker-compose up wipe-volumes
|
docker-compose up wipe-volumes
|
||||||
rm -rf workdir/*
|
# Note, we use explicit set of dirs so we don't delete .gitignore. Also,
|
||||||
|
# don't wipe logs between runs as they are already split and we need them to
|
||||||
|
# upload as artifacts later.
|
||||||
|
rm -rf workdir/{consul,envoy,bats,statsd}
|
||||||
mkdir -p workdir/{consul,envoy,bats,statsd,logs}
|
mkdir -p workdir/{consul,envoy,bats,statsd,logs}
|
||||||
|
|
||||||
# Reload consul config from defaults
|
# Reload consul config from defaults
|
||||||
|
@ -96,12 +99,7 @@ for c in ./case-*/ ; do
|
||||||
# can't use shared volumes)
|
# can't use shared volumes)
|
||||||
docker cp workdir/. envoy_workdir_1:/workdir
|
docker cp workdir/. envoy_workdir_1:/workdir
|
||||||
|
|
||||||
# Restart Consul. We don't just reload because some configs under test don't
|
# Start consul now as setup script needs it up
|
||||||
# work with reload and because you can get different effects from running
|
|
||||||
# tests in isolation which always have fresh Consul vs in the full suite.
|
|
||||||
# It's pretty quick to start and stop so this is better isolation.
|
|
||||||
echo "(Re)starting Consul"
|
|
||||||
docker-compose stop consul
|
|
||||||
docker-compose up -d consul
|
docker-compose up -d consul
|
||||||
|
|
||||||
# Copy all the test files
|
# Copy all the test files
|
||||||
|
@ -139,6 +137,8 @@ for c in ./case-*/ ; do
|
||||||
fi
|
fi
|
||||||
echo "================================================"
|
echo "================================================"
|
||||||
|
|
||||||
|
# Hack consul into the list of containers to stop and dump logs for.
|
||||||
|
REQUIRED_SERVICES="$REQUIRED_SERVICES consul"
|
||||||
|
|
||||||
# Teardown
|
# Teardown
|
||||||
if [ -f "${c}teardown.sh" ] ; then
|
if [ -f "${c}teardown.sh" ] ; then
|
||||||
|
|
Loading…
Reference in New Issue