From 2166733628bbab0eb77eeed58bdf204727c48ec6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jean-S=C3=A9bastien=20P=C3=A9dron?= Date: Thu, 29 Dec 2016 15:48:06 +0100 Subject: cowboy_static: Add support for files in EZ archives If cowboy_static is initialized with `{priv_file, ...}` or `{priv_dir, ...}`, it is now able to read files from Erlang application .ez archives. When serving a file from an archive, the #file_info{} comes from the archive, not the contained file, except for the size and type. The erl_prim_loader module is used to read the latter's #file_info{} and the actual file content (ie. sendfile(2) is not used in this case). --- test/static_handler_SUITE_data/static_files_app.ez | Bin 0 -> 1274 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 test/static_handler_SUITE_data/static_files_app.ez (limited to 'test/static_handler_SUITE_data') diff --git a/test/static_handler_SUITE_data/static_files_app.ez b/test/static_handler_SUITE_data/static_files_app.ez new file mode 100644 index 0000000..fdb0911 Binary files /dev/null and b/test/static_handler_SUITE_data/static_files_app.ez differ -- cgit v1.2.3