Login works fine. Getting error at /admin/logout
You must activate the logout in your security firewall configuration.
at
in *\vendor\sonata-project\user-bundle\Controller\AdminSecurityController.php at line 98
I'm setting logout to true as documented:
security.yml:
firewalls:
main:
pattern: .*
#pattern: ^/
form-login:
provider: fos_userbundle
csrf_provider: form.csrf_provider
login_path: /login
use_forward: false
check_path: /login_check
failure_path: null
logout: true
anonymous: true
How do you avoid this error using symfony2.4, fosuserbundle1.3 and sonata-admin dev-master ?
The logout
node in your security.yml should contain two subnodes defining the logout path and the target where a user gets redirected after a logout:
logout:
path: /admin/logout
target: /
Not sure if this also works in sonata context, but it should work under normal conditions.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With