I'm working on Symfony 4 project locally using symfony local web server. How to enable HTTPS locally?
- In docs https://symfony.com/doc/current/setup/symfony_server.html#enabling-tls said to use "symfony server:ca:install" command, but I get a error message:
There are no commands defined in the "server:ca" namespace. Did you mean one of these?
doctrine:cache
server
-
Then I found https://symfony.com/doc/current/security/force_https.html and tried to add
- { path: ^/, roles: IS_AUTHENTICATED_ANONYMOUSLY, requires_channel: https }
and clear cache after all. But now it redirected from http://127.0.0.1:8000 to https://127.0.0.1/ with no access to the site
So what is the correct way to configure https?
The main reason to enable https is I want to configure sign in with Facebook, but Facebook demands https connection. So I cannot test it. Or, if you know the way to test sign in with Facebook without https - it would be the best decision!)
Thank you in advance and have a good day who read it!)