Fix db core tests by making the network bw-docker entirely external

This commit is contained in:
Théophile Diot 2023-07-04 16:10:48 -04:00
parent 1cf281ef83
commit d6407b8186
No known key found for this signature in database
GPG Key ID: E752C80DB72BB014
4 changed files with 6 additions and 9 deletions

View File

@ -13,4 +13,4 @@ services:
networks:
bw-docker:
name: bw-docker
external: true

View File

@ -13,4 +13,4 @@ services:
networks:
bw-docker:
name: bw-docker
external: true

View File

@ -12,4 +12,4 @@ services:
networks:
bw-docker:
name: bw-docker
external: true

View File

@ -129,11 +129,11 @@ fi
for test in "local" "multisite" "mariadb" "mysql" "postgres"
do
echo "💾 Creating the bw-docker network ..."
docker network create bw-docker
if [ "$test" = "local" ] ; then
echo "💾 Running tests with a local database ..."
echo "💾 Creating the bw-docker network ..."
docker network create bw-docker
elif [ "$test" = "multisite" ] ; then
echo "💾 Running tests with MULTISITE set to yes and with multisite settings ..."
find . -type f -name 'docker-compose.*' -exec sed -i 's@MULTISITE: "no"$@MULTISITE: "yes"@' {} \;
@ -147,9 +147,6 @@ do
sed -i 's@GLOBAL_USE_REVERSE_PROXY@SERVICE_USE_REVERSE_PROXY@' docker-compose.test.yml
sed -i 's@GLOBAL_REVERSE_PROXY_HOST@SERVICE_REVERSE_PROXY_HOST@' docker-compose.test.yml
sed -i 's@GLOBAL_REVERSE_PROXY_URL@SERVICE_REVERSE_PROXY_URL@' docker-compose.test.yml
echo "💾 Creating the bw-docker network ..."
docker network create bw-docker
elif [ "$test" = "mariadb" ] ; then
echo "💾 Running tests with MariaDB database ..."
echo " Keeping the MULTISITE variable to yes and multisite settings ..."