© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
2 replies
sundays

S3 FileUpload tries to load preview from localhost

Forms\Components\FileUpload::make('file')
                    ->required()
                    ->label('Message file')
                    ->disk('messages')
                    ->maxSize(1024 * 20)
                    ->acceptedFileTypes(['audio/mpeg'])
Forms\Components\FileUpload::make('file')
                    ->required()
                    ->label('Message file')
                    ->disk('messages')
                    ->maxSize(1024 * 20)
                    ->acceptedFileTypes(['audio/mpeg'])


When I use
Storage::disk('messages')->url();
Storage::disk('messages')->url();
with the file name stored in the database I get the correct URL back to the s3 bucket. But in the admin panel, filament seems to be trying to load the file from localhost no matter what I do. I tried setting visibility to 'public' or 'private' but that didn't help. My ACL is disabled. AWS_URL is set and the disk filesystem is configured correctly, any ideas?
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Preview images from S3
FilamentFFilament / ❓┊help
3y ago
Fileupload to AWS S3
FilamentFFilament / ❓┊help
2y ago
Error FileUpload Preview
FilamentFFilament / ❓┊help
2y ago
FileUpload custom preview.
FilamentFFilament / ❓┊help
2y ago