error 403 in production

I have a problem with my project that I have tried to put into production, it is a project where I have 3 panels, in the admin panel I have created an Admin model to which I have added what the page https://v2.filamentphp.com/ indicates tricks/admin-403-in-production that is, add the implements FilamentUser but it doesn't work, it keeps giving me the 403 error, any idea where else the problem could be? Thank you so much... This is my code <?php namespace App\Models; use Filament\Models\Contracts\FilamentUser; use Filament\Panel; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; use Illuminate\Foundation\Auth\User as Authenticatable; use Illuminate\Notifications\Notifiable; use Illuminate\Support\Collection; use Laravel\Sanctum\HasApiTokens; class Admin extends Authenticatable implements FilamentUser { use HasApiTokens, HasFactory, Notifiable; /** * The attributes that are mass assignable. * * @var array<int, string> */ protected $fillable = [ 'name', 'email', 'password', ]; /** * The attributes that should be hidden for serialization. * * @var array<int, string> */ protected $hidden = [ 'password', 'remember_token', ]; /** * The attributes that should be cast. * * @var array<string, string> */ protected $casts = [ 'email_verified_at' => 'datetime', 'password' => 'hashed', ]; public function canAccessPanel(Panel $panel): bool { // return str_ends_with($this->email, '@seashell-app-mcfdv.ondigitalocean.app') && $this->hasVerifiedEmail(); } }
Filament
Filament - Accelerated Laravel development framework: admin panel, ...
A collection of beautiful full-stack components for Laravel. The perfect starting point for your next app. Using Livewire, Alpine.js and Tailwind CSS.
1 Reply
TranceCode
TranceCodeOP14mo ago
i fix the problem adding APP_ENV=local in the Evironment, this is because i create an app on digital ocean, not a droplet.
Want results from more Discord servers?
Add your server