Add "Download Folder" option to file_server?

Is it possible to add a button next to folders that when clicked zip up the contents of that folder and send it to the user, kinda like Google Drive? Perhaps with an option to only allow downloading with a max depth of N to not overload the server by downloading one of the root folders.

So far I’m thinking you could modify the browse template here: caddy/modules/caddyhttp/fileserver/browse.html at master · caddyserver/caddy · GitHub which allows you to add the button, but how can I actually implement the zipping and serving portion?

This would be a very nice feature.

This would require a plugin. The zipping would need to be performed server-side.

You might want to use something like GitHub - filebrowser/filebrowser: 📂 Web File Browser instead which has this functionality. Configure Caddy to proxy to it.