Error while uploading the file

I try to upload files locally and it works fine, when I try to upload it on production I get this error response with an empty message:
11 Replies
LeandroFerreira
LeandroFerreira16mo ago
php artisan storage:link did you config APP_URL in the .env file?
YoussefMaged
YoussefMagedOP16mo ago
Yes I will try that and tell you Thank you Leandro
YoussefMaged
YoussefMagedOP16mo ago
This is the output, I did php artisan storage:link php artisan tenants:run storage:link and this was the output and it's still failing, I suspect it's storage write permissions on my server but I'm not sure where should I touch
YoussefMaged
YoussefMagedOP16mo ago
LeandroFerreira
LeandroFerreira16mo ago
in app/Http/Middleware/TrustProxies.php set this protected $proxies = '*';
YoussefMaged
YoussefMagedOP16mo ago
I did so and I'm still getting the same error
Abdur Razzaque
Abdur Razzaque16mo ago
Maybe your directory is not correct
YoussefMaged
YoussefMagedOP16mo ago
I'm trying to fetch the directory it tries to go to through the request but with no success, maybe I'm missing something?
Abdur Razzaque
Abdur Razzaque16mo ago
Yap! Can you share the way of your uploading process?
YoussefMaged
YoussefMagedOP16mo ago
That's from a spatie laravel settings filament page
protected function getFormSchema(): array
{
return [
Card::make()
->schema([
FileUpload::make('app_logo_url')
->label(__('ch-system.page_settings.app_logo_url'))
->preserveFilenames()
->image(),
Select::make('confession_father_role_id')
->label(__('ch-system.page_settings.confession_father_role_name'))
->options(Role::all()->pluck('name', 'id'))
->searchable(),
])
->inlineLabel(),
];
}
protected function getFormSchema(): array
{
return [
Card::make()
->schema([
FileUpload::make('app_logo_url')
->label(__('ch-system.page_settings.app_logo_url'))
->preserveFilenames()
->image(),
Select::make('confession_father_role_id')
->label(__('ch-system.page_settings.confession_father_role_name'))
->options(Role::all()->pluck('name', 'id'))
->searchable(),
])
->inlineLabel(),
];
}
Most probably because I'm uploading from a different domain name which is a tenant and the APP_URL is set to the central version of the app? But I need this functionality so how to avoid that 401 signature validation?
Want results from more Discord servers?
Add your server