morningtrain / laravel-https
Provides some initial https setup
Installs: 2 830
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 4
Forks: 0
Open Issues: 0
Requires
- php: ^7.2|^8.0
- illuminate/support: ^5.8|^6.0|^7.0|^8.0|^9.0|^10.0
README
Install
Via Composer
$ composer require morningtrain/laravel-https
Usage
Deploy the config files.
$ php artisan vendor:publish
Update the following in your .env
:
USE_SSL=true
REDIRECT_TO_HTTPS=true
Register the ForceSSL middleware as a global middleware in your App\Httk\Kernel
class:
class Kernel extends HttpKernel { /** * The application's middleware stack. * * @var array */ protected $middleware = [ \MorningTrain\Laravel\Https\Http\Middleware\ForceSSL::class, ]; }