A dead-simple multi-threaded web and file server.
You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Johannes Wünsche 100fea5c72 fix webserve flag action 2 months ago
data Add icon 2 years ago
src fix webserve flag action 2 months ago
tests update clap 2 months ago
.gitignore Add file server test 2 years ago
Cargo.lock update walkdir 2 months ago
Cargo.toml update walkdir 2 months ago
Dockerfile update CLI usage Dockerfile 2 months ago
README.md Fix image link for new gitea version 2 years ago


rusty-conveyor - a simple multi-threaded web and file server

A no config static binary to host web and file server via http


No prebuilt binaries are provided at the moment. To use the application you'll have to build it yourself. For this you'll need a configured Rust toolchain. Check out the page rust-lang page for a quick setup.

When you have everything setup, clone the repository and use cargo to build the repository.

$ git clone https://git.spacesnek.rocks/johannes/rusty-conveyor.git
$ cd rusty-conveyor
$ # Build for the release target
$ # this will drastically decrease the size of the resulting binaries
$ cargo build --release

Usage with Container Environments

A Dockerfile is given that produces a container able to mount files to /data with a single statically linked binary. The default mode for the container is the web mode automatically indexing to index.html files on directories. You can then mount your files to /data like this:

$ # Use any compatible container client you want e.g. docker, podman ...
$ podman -v ./your-files:/data -p 7331:7331 rusty-conveyor


$ ./rusty-conveyor --help
rusty-conveyor 0.1
Johannes Wünsche <johannes@spacesnek.rocks>
A dead simple multi-threaded web and file server via http.

    rusty-conveyor [FLAGS] [OPTIONS]

    -h, --help       
            Prints help information

    -V, --version    
            Prints version information

    -w, --web        
            Serve files in style of a web server. In detail things like `index.html` can be omitted in the address to
            better serve usable for web browsers.

    -a, --address <ADDRESS>    
            The address on which the application should bind to. This can be any identifier e.g. localhost or IP
            configured. [default:]
    -d, --directory <DIR>      
            The directory in which files are served from. Any path can be, as content are held in memory to deliver fast
            response the total size of files should not be larger than available memory. [default: .]
    -p, --port <PORT>          
            The port on which the application binds to on the given address. [default: 7331]


For https use a reverse proxy like traefik or sozu.