Legendary Trio
devlogquedulaux

Devlog #10: Video preview before publishing

Before queuing a video for publication, the user should be able to watch it. This seems obvious but the implementation requires several steps.

The video is stored in object storage. For playback in the browser we need a temporary read-access URL. We generate a presigned URL server-side with a limited lifetime and return it to the frontend.

One subtlety: the presigned URL should be generated fresh on each page open, not cached. A URL with an expired lifetime will produce an error when playback is attempted.

For mobile devices we also check the video MIME type — some browsers handle certain formats poorly.