See: https://github.com/laravel/framework/pull/47309
# Laravel 11 Skeleton Overview
### General Notes
More environment variables have been added to the `.env.example` file.
The default `QUEUE_CONNECTION` variable value has been updated to `database` instead of `sync`.
The `BROADCAST_DRIVER` and `CACHE_DRIVER` environment variables have been renamed to `BROADCAST_CONNECTION` and `CACHE_STORE`, respectively.
The HTTP Kernel has been removed. Configuration that was previously done in this file can be done in the `bootstrap/app.php` file, including registering / replacing middleware.
The console kernel has been removed. Schedules can be defined in the console “routes” file. Commands generated by `make:command` are automatically loaded and do not require registration. Additional command loading paths can be registered in the `bootstrap/app.php` file.
The exception handler has been removed. Exception handling behavior can be configured in the `bootstrap/app.php` file via `reportable`, `renderable`, `throttle`, and more. Callbacks received by these functions will have their type hints inspected to see if they handle a given exception.
The base HTTP controller no longer extends any other classes (requiring new middleware definition feature). No traits are included by default on the base controller. Authorization can be done using facades, or traits can be added manually.
All middleware has been removed. Configuration of these middleware’s behavior can be done via static methods on the middleware themselves (see framework notes).
The `User` model now utilizes a `casts` method instead of a property. The `HasApiTokens` trait has been removed by default since Sanctum is not installed by default.
All service providers except the `AppServiceProvider` have been removed. Policies are auto-discovered and gates can be registered in `AppServiceProvider`. Likewise, events can be registered in `AppServiceProvider`. Routing behavior is now determined / customized in the `bootstrap/app.php` file.
New `bootstrap/app.php` file can be used to customize core framework behavior like routing, container bindings, middleware, and exception handling.
Sanctum is no longer installed by default (see `install:api`).
Configuration files are not present by default. Can be published by `config:publish` command. Default values are present in the framework and application level configuration now cascades with framework definitions, so only customized values need be present in application level configuration files.
Migration files have been re-dated to be evergreen. The `password_reset_tokens` table migration has been combined into the `users` table migration file. Likewise, the `jobs` table migration has been combined into a single migration with the `failed_jobs` table.
Echo bootstrapping has been removed by default. It is re-inserted by new `install:broadcasting` command.
API and channel routes files are not present by default, can be recreated by `install:api` and `install:broadcasting` respectively.
Add `local_domain` as an option to the smtp configuration. This can be used to change the domain that is used to send the `EHLO` command during the SMTP handshake.
`null` is a sensible default since Symfony/Mailer will use it's own default (`127.0.0.1`) to send the mail.
Co-authored-by: Bram in 't Zandt <bram@bigspark.com>
* Add option to set sendmail path. Fix default
Testing this in an application, it would seem that sendmail -bs is the wrong option for this case?
What Laravel appears to do is pipe an RFC-2822 formatted message on STDIN and requires the sendmail emulation to deal with it,
rather than -bs which initiates an SMTP session.
if Exim is the default MTA then -t would seem to be the correct option.
If you have an alternative installed instead of sendmail/exim, then there's no way to set the path, so I added MAIL_SENDMAIL_PATH
so you can do, e.g.:
MAIL_SENDMAIL_PATH="/usr/bin/msmtp -t --tls=off --from=${MAIL_FROM_ADDRESS} --auto-from=off"
msmtp doesn't support -bs at all
* Update mail.php
Co-authored-by: Taylor Otwell <taylor@laravel.com>
* Allow configuring the timeout for the smtp driver
The default is the same as in `\Swift_Transport_EsmtpTransport::$params`
* Corrected default
* Update mail.php
Co-authored-by: Graham Campbell <GrahamCampbell@users.noreply.github.com>
Co-authored-by: Taylor Otwell <taylor@laravel.com>