potiuk commented on a change in pull request #9126:
URL: https://github.com/apache/airflow/pull/9126#discussion_r435163935



##########
File path: scripts/ci/in_container/check_environment.sh
##########
@@ -120,61 +120,6 @@ function check_db_connection {
     echo 
"-----------------------------------------------------------------------------------------------"
 }
 
-function check_mysql_logs {
-    MAX_CHECK=${1:=60}
-    # Wait until mysql is ready!
-    MYSQL_CONTAINER=$(docker ps -q -f "name=mysql" -f "volume=/dev/urandom")
-    if [[ -z ${MYSQL_CONTAINER} ]]; then
-        echo
-        echo "ERROR! MYSQL container is not started. Exiting!"
-        echo
-        exit 1
-    elif [[ "${MYSQL_CONTAINER}" = *$'\n'* ]]; then
-        echo
-        echo "ERROR! pattern match multiple MYSQL containers. Exiting! 
Container ids as below:"
-        echo
-        echo "${MYSQL_CONTAINER}"
-        echo
-        exit 1
-    fi
-    echo
-    echo "Checking if MySQL is ready for connections (double restarts in the 
logs)"
-    echo
-    while true
-    do
-        CONNECTION_READY_MESSAGES=$(docker logs "${MYSQL_CONTAINER}" 2>&1 | \

Review comment:
       Yes. It turned out we do not need it as we have the DB check that 
follows. I actually discovered why we had the previous "host name" mismatches. 
What happens is that sometimes it took a bit long to make those two restarts 
when DB was created and while this was happening the DNS names was not properly 
set in the database. I simply increased the maximum number of checks in the DB 
check and it started to work correctly - waiting until the DN restarts and is 
ready.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to