aboutsummaryrefslogtreecommitdiffstats
path: root/autotest.sh
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2016-09-13 20:42:31 +0200
committerMorris Jobke <hey@morrisjobke.de>2016-09-13 20:52:55 +0200
commit11cc8903bb3a2a645bddeddc7ef45bbfe30ef99f (patch)
tree4c6c17fd38caf5225246548f68361e04dd009829 /autotest.sh
parentb6439da1288d629eaf07d3d6f2497f3583fd11e7 (diff)
downloadnextcloud-server-11cc8903bb3a2a645bddeddc7ef45bbfe30ef99f.tar.gz
nextcloud-server-11cc8903bb3a2a645bddeddc7ef45bbfe30ef99f.zip
add actual check if mysql is up already
Diffstat (limited to 'autotest.sh')
-rwxr-xr-xautotest.sh13
1 files changed, 5 insertions, 8 deletions
diff --git a/autotest.sh b/autotest.sh
index 022d4ecd4b6..2dfa961a1a2 100755
--- a/autotest.sh
+++ b/autotest.sh
@@ -191,14 +191,6 @@ function execute_tests {
-d mysql)
DATABASEHOST=$(docker inspect --format="{{.NetworkSettings.IPAddress}}" "$DOCKER_CONTAINER_ID")
- echo "Waiting for MySQL initialisation ..."
- if ! apps/files_external/tests/env/wait-for-connection $DATABASEHOST 3306 600; then
- echo "[ERROR] Waited 600 seconds, no response" >&2
- exit 1
- fi
-
- echo "MySQL is up."
-
else
if [ -z "$DRONE" ] ; then # no need to drop the DB when we are on CI
if [ "mysql" != "$(mysql --version | grep -o mysql)" ] ; then
@@ -211,6 +203,11 @@ function execute_tests {
DATABASEHOST=127.0.0.1
fi
fi
+ echo "Waiting for MySQL initialisation ..."
+ if ! apps/files_external/tests/env/wait-for-connection $DATABASEHOST 3306 600; then
+ echo "[ERROR] Waited 600 seconds, no response" >&2
+ exit 1
+ fi
fi
if [ "$DB" == "mariadb" ] ; then
if [ ! -z "$USEDOCKER" ] ; then