dufs - A Simple File Server

2024-12-24

Need a minimal file sharing server? dufs would be the perfect tool for that. Here is my setup.

Get dufs

cargo install dufs (with Cargo), or you can install with brew or docker (see the github repo for details).

Configure the server

dufs -p <port> --allow-upload -a <username>:<password>@/:rw <data-path>

This serves data from <data-path> (which can be a directory or file) on port <port>. Upload is allowed and the server is protected with the given creds. There are various settings for different use cases but this is what I need for my server.

Expose the server to public

Use free cloud flare tunnel.

Alternatives

dufs is written in Rust, and is super minimalist and fast. It's exactly what I needed for my use case but there are other heavier and fancier tools (excluding the giant dropbox-like apps such as nextcloud) for consideration.

  • FileGater: written in PHP, it's too heavy for my taste and for the job.
  • FileBrowser: written in Go and Vue.js. Though it's a bit more modern, it is still over engineered.
  • simple-http-server: this looks pretty close to dufs.