Closed Sam-Xronn closed 4 years ago
The email wasn't added to the gate now the application has gone from local to production.
app/Providers/NovaServiceProvider.php
In the production environment, Nova can only access by the user that is find in the Gate in the NovaServiceProvider. You have to specify the user or the role of users that can access.
/**
* Register the Nova gate.
*
* This gate determines who can access Nova in non-local environments.
*
* @return void
*/
protected function gate()
{
Gate::define('viewNova', function ($user) {
return in_array($user->email, [
'admin@email.com'
]);
});
}
Please explain that in the documentation.
Please explain that in the documentation.
It's right there https://nova.laravel.com/docs/3.0/installation.html#authorizing-nova
Please explain that in the documentation.
It's right there https://nova.laravel.com/docs/3.0/installation.html#authorizing-nova
New link https://nova.laravel.com/docs/installation.html#authorizing-access-to-nova
Description:
When logging in with correct user credentials the user is forwarded from
/nova/login
to/nova
however a 403 forbidden error is thrown. It's now impossible for the user to logout (a session does exists) or accesses any part of the nova CMS.Following the steps from a past issue request no longer works. https://github.com/laravel/nova-issues/issues/1633
It does state logging in as a user that doesn't have
permission
I see nothing in the docs regarding this.Steps To Reproduce:
Login to nova using the correct details. We have found a single user account that logins in successfully every time, however, any other user account fails.
Note* No changes have been made to the user's table