FilamentF
Filament2y ago
Mike

S3 image upload not getting full url?

I have a fileupload field called featured_image. Im uploading the files to s3 disk, all good with that however the content saved to the database is just the file name saved into s3 and not the full url, so in this case previews dont work etc. I also have tiptap plugin installed which works all good.
What am i missing? Thank you

FileUpload::make('meta_image')
->label('Featured image')
->image()
->disk('s3')
->directory('images/posts')
->visibility('public')
->maxSize(2048)
->required(),

My s3 filesystem config:
's3' => [
'driver' => 's3',
'key' => env('AWS_ACCESS_KEY_ID'),
'secret' => env('AWS_SECRET_ACCESS_KEY'),
'region' => env('AWS_DEFAULT_REGION'),
'bucket' => env('AWS_BUCKET'),
'url' => env('AWS_URL'),
'endpoint' => env('AWS_ENDPOINT'),
'use_path_style_endpoint' => env('AWS_USE_PATH_STYLE_ENDPOINT', false),
'throw' => false,
],
Was this page helpful?