Skip to content

Commit fd42e10

Browse files
Changes localhost to 127.0.0.1 in database config
In laravel#3641 was decided to use `127.0.0.1` instead of `localhost` to avoid DNS lookups This change is to maintain consistency between `.env` and `database.php`
1 parent e72463d commit fd42e10

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

config/database.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454

5555
'mysql' => [
5656
'driver' => 'mysql',
57-
'host' => env('DB_HOST', 'localhost'),
57+
'host' => env('DB_HOST', '127.0.0.1'),
5858
'port' => env('DB_PORT', '3306'),
5959
'database' => env('DB_DATABASE', 'forge'),
6060
'username' => env('DB_USERNAME', 'forge'),
@@ -68,7 +68,7 @@
6868

6969
'pgsql' => [
7070
'driver' => 'pgsql',
71-
'host' => env('DB_HOST', 'localhost'),
71+
'host' => env('DB_HOST', '127.0.0.1'),
7272
'port' => env('DB_PORT', '5432'),
7373
'database' => env('DB_DATABASE', 'forge'),
7474
'username' => env('DB_USERNAME', 'forge'),

0 commit comments

Comments
 (0)