In dev mode, allow blank root password.

This commit is contained in:
Steve Ireland committed 2023-06-25 12:16:51 -04:00
1 parent ab8989c3cd
commit 8db87fd5ab
1 file changed
+14 -3
+14 -3
View File
@@ -102,9 +102,20 @@ class Database extends Config
{
parent::__construct();
$this->development['hostname'] = getenv('MYSQL_HOST_NAME') ? getenv('MYSQL_HOST_NAME') : 'localhost';
$this->development['username'] = getenv('MYSQL_USERNAME') ? getenv('MYSQL_USERNAME') : 'admin';
$this->development['password'] = getenv('MYSQL_PASSWORD') ? getenv('MYSQL_PASSWORD') : 'pointofsale';
if(!getenv('database.development.hostname'))
{
$this->development['hostname'] = getenv('database.development.hostname');
}
if(!getenv('database.development.hostname'))
{
$this->development['username'] = getenv('database.development.username');
}
if(!getenv('database.development.hostname'))
{
$this->development['password'] = getenv('database.development.password');
}
// Ensure that we always set the database group to 'tests' if
// we are currently running an automated test suite, so that