From 771ee7adeaca7978b18176e941c83d2fe552310c Mon Sep 17 00:00:00 2001 From: pavemaksim Date: Thu, 31 Aug 2017 15:34:02 +0300 Subject: [PATCH] DSN configuration example added to readme --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/README.md b/README.md index 806229f52..04984a575 100644 --- a/README.md +++ b/README.md @@ -143,6 +143,18 @@ You can connect to multiple servers or replica sets with the following configura ], ``` +Alternatively, you can use MongoDB connection string: + +```php +'mongodb' => [ + 'driver' => 'mongodb', + 'dsn' => env('DB_DSN'), + 'database' => env('DB_DATABASE'), +], +``` + +Please refer to MongoDB official docs for its URI format: https://docs.mongodb.com/manual/reference/connection-string/ + Eloquent --------