From 28c7d576a57cb1bb1373848ada14a449d2ecfa3e Mon Sep 17 00:00:00 2001 From: NGPixel Date: Sun, 5 Jul 2020 20:56:24 -0400 Subject: [PATCH] test: cypress mariadb debug (2) --- dev/cypress/ci-setup.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/dev/cypress/ci-setup.sh b/dev/cypress/ci-setup.sh index 0c836fa5..5f388b3e 100644 --- a/dev/cypress/ci-setup.sh +++ b/dev/cypress/ci-setup.sh @@ -7,11 +7,19 @@ postgres) mysql) echo "Using MySQL..." docker run -d -p 3306:3306 --name db --network="host" -e "MYSQL_ROOT_PASSWORD=Password123!" -e "MYSQL_USER=wiki" -e "MYSQL_PASSWORD=Password123!" -e "MYSQL_DATABASE=wiki" mysql:8 + while ! docker exec db mysql --user=root --password=Password123! -e "SELECT 1" &> /dev/null ; do + echo "Waiting for database connection..." + sleep 2 + done docker run -d -p 3000:3000 --name wiki --network="host" -e "DB_TYPE=mysql" -e "DB_HOST=localhost" -e "DB_PORT=3306" -e "DB_NAME=wiki" -e "DB_USER=wiki" -e "DB_PASS=Password123!" requarks/wiki:canary-2.5.67 ;; mariadb) echo "Using MariaDB..." docker run -d -p 3306:3306 --name db --network="host" -e "MYSQL_ROOT_PASSWORD=Password123!" -e "MYSQL_USER=wiki" -e "MYSQL_PASSWORD=Password123!" -e "MYSQL_DATABASE=wiki" mariadb:10 + while ! docker exec db mysql --user=root --password=Password123! -e "SELECT 1" &> /dev/null ; do + echo "Waiting for database connection..." + sleep 2 + done docker run -d -p 3000:3000 --name wiki --network="host" -e "DB_TYPE=mariadb" -e "DB_HOST=localhost" -e "DB_PORT=3306" -e "DB_NAME=wiki" -e "DB_USER=wiki" -e "DB_PASS=Password123!" requarks/wiki:canary-2.5.67 ;; mssql)