I am unable to upload images after deploying Filament Admin panel on server

I’ve deployed my Laravel app on a DigitalOcean server, but I’ve had to use a slightly different folder structure for the public and other Laravel files: Public files: https://example.com/html/my-project/my-first-filament-app/ Laravel app files: https://example.com/laravel/my-project/ My web URL is: https://example.com/my-first-filament-app/. I’ve updated the public path and app bindings to reflect this structure, and everything works fine so far. I’ve also set custom routes for Livewire as it was throwing a 404 due to the structure:
Livewire::setUpdateRoute(function ($handle) {
return Route::post('/my-first-filament-app/livewire/update', $handle);
});

Livewire::setScriptRoute(function ($handle) {
return Route::get('/my-first-filament-app/livewire/livewire.js', $handle);
});
Livewire::setUpdateRoute(function ($handle) {
return Route::post('/my-first-filament-app/livewire/update', $handle);
});

Livewire::setScriptRoute(function ($handle) {
return Route::get('/my-first-filament-app/livewire/livewire.js', $handle);
});
These changes have resolved my issues with Livewire, but now I’m encountering an “Unauthorized” error when trying to upload images via the Filament panel. The issue occurs on the /livewire/upload-file endpoint.
No description
No description
2 Replies
SimonH
SimonH3mo ago
The issue might be related to the signature validation when installing in a sub-folder. You can see this discussed in this issue with a possible solution https://github.com/livewire/livewire/discussions/3084#discussioncomment-8621020
GitHub
File upload over https fails signature verification · livewire live...
Fille uploads doesn't work over https, whereas it works perfectly over http Set up livewire file upload, then use https (e.g. with ngrok) the upload fails with the request to Request URL: https...
AlokDev
AlokDevOP3mo ago
I have tried all of them but it's not working. I have avoid unauthorized error but files are still not uploading to storage folder I have manually created this folder in both places and they are symlink with each other. Public files: https://example.com/html/my-project/my-first-filament-app/storage Laravel app files: https://example.com/laravel/my-project/storage/app/public I have able to upload the images thanks
Want results from more Discord servers?
Add your server