[erlang-questions] Cowboy serve static files [video file] can not fast forward

Marc Worrell <>
Wed Jul 18 11:16:21 CEST 2018

We (Zotonic) also implemented range requests in cowmachine.

https://github.com/zotonic/cowmachine/blob/master/src/cowmachine_response.erl#L72 <https://github.com/zotonic/cowmachine/blob/master/src/cowmachine_response.erl#L72>

Cowmachine is the Webmachine variant for the new version of Zotonic.
It uses Cowboy instead of Mochiweb, and simplified the controller callbacks.

- Marc

> On 18 Jul 2018, at 10:06, by <> wrote:
> OK
> I will try cowboy_rest.
> Thanks
>> 在 2018年7月18日,15:59,Loïc Hoguin <> 写道:
>> Someone did a partial implementation for cowboy_rest here: https://github.com/ninenines/cowboy/pull/1059
>> But you'll have to make your own handler (or a wrapper of cowboy_static).
>> Adding proper support is currently not prioritized, it's not been necessary for customers yet and I still have a few more important tasks to do (better Websocket, better cookies, and CORS support being the next big three, and of course Ranch 2.0).
>> On 07/18/2018 08:28 AM, by wrote:
>>> Well, I see.
>>> Is there any existing resolution about this? Maybe third party handler?
>>> I believe the requirements for serving video liked content is very common.
>>>> 在 2018年7月18日,14:08,Loïc Hoguin <> 写道:
>>>> If I recall that's because the static files handler does not support range requests yet.
>>>> On 07/18/2018 05:21 AM, by wrote:
>>>>> Hi,
>>>>> I am trying to serve a static website via Cowboy, and I followed the guide, it seems works fine.
>>>>> The problem is that the static website has a mp4 file, and I play the video on web page.
>>>>> It can play, but when I try to click the progress bar to do fast forward, it keeps play on the normal way(not work).
>>>>> Do I need add some other configurations for this?
>>>>> Same static files works fine with nginx.
>>>>> Thanks,
>>>>> Yao Bao
>>>>> _______________________________________________
>>>>> erlang-questions mailing list
>>>>> http://erlang.org/mailman/listinfo/erlang-questions
>>>> -- 
>>>> Loïc Hoguin
>>>> https://ninenines.eu
>> -- 
>> Loïc Hoguin
>> https://ninenines.eu
> _______________________________________________
> erlang-questions mailing list
> http://erlang.org/mailman/listinfo/erlang-questions

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20180718/a31ae14e/attachment.html>

More information about the erlang-questions mailing list