php - Laravel Sail: could not find driver (SQL: SHOW FULL TABLES WHERE table_type = 'BASE TABLE') --- Mac

one text

I just recently replaced my macbook. I setup the previous project I was working on. Unfortunately I encountered this error.


  could not find driver (SQL: SHOW FULL TABLES WHERE table_type = 'BASE TABLE')

  at vendor/laravel/framework/src/Illuminate/Database/Connection.php:712
    708?��         // If an exception occurs when attempting to run a query, we'll format the error
    709?��         // message to include the bindings with SQL, which will make this exception a
    710?��         // lot more helpful to the developer instead of just the database's errors.
    711?��         catch (Exception $e) {
  ??? 712?��             throw new QueryException(
    713?��                 $query, $this->prepareBindings($bindings), $e
    714?��             );
    715?��         }
    716?��     }

I'm using laravel/sail so all services are defined on docker-compose.yml.

All services are running properly without any errors via command $ sail up -d.

I can even connect to mysql service using TablePlus App.

Is there any new config I might have missed?

I tried checking DB connection using tinker and here is the output (no connection error found).

>>> DB::connection();
=> Illuminate\Database\MySqlConnection {#525}
>>> 

Source