user_6ed0f
Chevereto Member
I am experiencing an issue with video uploads in my Chevereto application to external storage s3 bucket where the uploaded video files are incorrectly set with the Content-Type as mp4 but in metadata it shows image/jpeg instead of video/mp4. This issue prevents the video files from loading.
Thank you for your support.
Application Details:
- Application Name: Chevereto
- Version: [Specify the version you are using]
- Hosting Environment: VPS
- External Storage: AWS S3
- Bucket Name: yalikeit-storage
- Region: us-east-2
Steps to Reproduce the Issue:
- Log in to Chevereto as an administrator.
- Navigate to the upload page.
- Upload a video file (e.g., .mp4).
- Check the uploaded file in the AWS S3 bucket.
Example:
- Uploaded File Name: riley.brush25_1717007412_7374490656883903786.mp4
- External Storage Config
- Storage Name: AWS S3
- Storage Type: Amazon S3
- Bucket Name: *****-storage
- Region: us-east-2
- Access Key: *********
- Secret Key: ***********
- URL: https://*****-storage.s3.us-east-2.amazonaws.com/
- Cheverto Links After Upload
- url: https://*****-storage.s3.us-east-2.amazonaws.com/2024/06/18/riley.brush25_1717007412_7374490656883903786.fr.mp4
- url_frame: https://*****-storage.s3.us-east-2.amazonaws.com/2024/06/18/riley.brush25_1717007412_7374490656883903786.fr.fr.jpeg
- url_short: https://*****.photos/image/leTdB
- url_viewer: https://*****.photos/image/riley.brush25-1717007412-7374490656883903786.leTdB
- S3 Object URL
- https://*****-storage.s3.us-east-2.amazonaws.com/2024/06/18/riley.brush25_1717007412_7374490656883903786.mp4
- When I visit the url above nothing loads but a broken tiny icon.
- https://*****-storage.s3.us-east-2.amazonaws.com/2024/06/18/riley.brush25_1717007412_7374490656883903786.mp4
- Type: mp4
- S3 Object Metadata
Type Key Value System defined Cache-Control public, max-age=31536000 System defined Content-Type image/jpeg
Observed Behavior:
- The uploaded video file in S3 has the Content-Type set to mp4 but metadata as image/jpeg.
- The video can't be viewed via direct link from the bucket or in cheverto
- If I upload directly to the bucket via aws cli it works fine and is correct but when uploading via cheverto it doesn't work.
Expected Behavior:
- The uploaded video file should have the Content-Type set to video/mp4.
Configuration Settings:
- Allowed File Extensions: JPG, JPEG, PNG, BMP, GIF, WEBP, MOV, MP4, WEBM
- Maximum Upload File Size: 32 MB (64 MB server limit)
- Storage Mode: Datefolders (/2024/06/18/ structure)
- File Naming Method: Original
Additional Information:
- I have verified the AWS S3 bucket policy to ensure public read access.
- The issue persists despite setting the correct Content-Type manually in S3 after upload.
Request:
I would appreciate your assistance in resolving this issue. Specifically, I need help to ensure that Chevereto correctly sets the Content-Type to video/mp4 for video uploads to S3. Any guidance on where to adjust the upload handling code or additional configuration settings would be helpful.Thank you for your support.