Laravel php artisan serve to mimic HTTPS

后端 未结 3 942
失恋的感觉
失恋的感觉 2021-01-04 00:38

I have been searching around to see if there is a way I can mock SSL for local development using Laravel\'s artisan to serve HTTPS with no luck.

Is this possible and

3条回答
  •  悲&欢浪女
    2021-01-04 00:47

    Laravel uses the in-built PHP5.4 development server php -S (http://php.net/manual/en/features.commandline.webserver.php) for it's artisan serve command (see Illuminate\Foundation\Console\ServeCommand). This only supports plain HTTP, so no, this isn't possible. Your best bet would be to use a Vagrant box set up to work with SSL/TLS.

提交回复
热议问题