diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 6e99f86..8522dc6 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -34,6 +34,7 @@ services: variables: COMPOSER: 'inc/test/composer.json' # Configure mysql environment variables (https://hub.docker.com/r/_/mysql/) + MYSQL_HOST: '127.0.0.1' MYSQL_DATABASE: mysql_database MYSQL_USERNAME: root MYSQL_PASSWORD: mysql_strong_password diff --git a/inc/test/php/EnvSettings.php b/inc/test/php/EnvSettings.php index 612edb7..1edb501 100644 --- a/inc/test/php/EnvSettings.php +++ b/inc/test/php/EnvSettings.php @@ -3,6 +3,7 @@ class EnvSettings extends Settings { public function __construct($connect = true) { parent::__construct(false); + $this->host = getenv("MYSQL_HOST"); $this->database = getenv("MYSQL_DATABASE"); $this->username = getenv("MYSQL_USERNAME"); $this->password = getenv("MYSQL_PASSWORD");