LoginSignup
0
0

More than 3 years have passed since last update.

Laravelでsqliteを使う方法

Posted at

1. database直下にデータベースファイルを作成

$touch database/database.sqlite

2. .envを編集

DB_CONNECTION=sqlite
# DB_HOST=127.0.0.1
# DB_PORT=3306
# DB_DATABASE=homestead
# DB_USERNAME=homestead
# DB_PASSWORD=secret

DB_CONNECTIOをsqliteにして、それ以外はコメントアウト

3.最後にマイグレーション

$ php artisan migrate
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0