Dev environment setup

This post will go through the initial setup of a Laravel and inertia js app with the development on docker with the help of Laravel sail

  • had an error here on WSL2 – the solution is: closing docker, wsl --shutdown and restarting docker has cleared this up at least once now

The installation steps are the one defined in the laravel docs – https://laravel.com/docs/8.x/sail#introduction – so for more detail head over there

So this is what my initial setup looks like:

  • curl -s https://laravel.build/greatreads | bash
  • alias sail=’bash vendor/bin/sail’
  • sail up -d → the -d flag is to start the containers in the background and not spit out a bunch of logs in your terminal, but if you’re into that, just remove the flag
  • sail composer require laravel/telescope
  • sail php artisan telescope:install
  • sail composer require laravel/horizon
  • sail php artisan horizon:install
  • sail composer require laravel/socialite
  • composer require –dev barryvdh/laravel-ide-helper and followed the steps from https://github.com/barryvdh/laravel-ide-helper – I work with PHPStorm so I need this
  • php artisan vendor:publish –provider=”Laravel\Sanctum\SanctumServiceProvider”