VueFinder Rust
Rust serverside implementation for VueFinder. Frontend: https://github.com/n1crack/vuefinder
Installation
As a Binary
Install the standalone server using cargo:
As a Library
Add to your project's Cargo.toml
:
[]
= "*"
Or using cargo add:
Usage
There are three ways to use VueFinder:
1. As a Standalone Binary
Install and run VueFinder as a standalone server:
# Development
# Production
The server will start at http://localhost:8080
by default. You can customize using command line options:
-p, --port <PORT>
: Specify server port [default: 8080]-b, --host <HOST>
: Specify binding address [default: 127.0.0.1]-l, --local-storage <PATH>
: Specify local storage path [default: ./storage]
# Examples
2. As a Library with Router
Integrate VueFinder into your existing Actix-Web application:
use ;
use HashMap;
use Arc;
use ;
async
3. As a Library with Custom Implementation
Use VueFinder's components to build your own file management system:
use ;
// Create your own storage adapter
;
// Create VueFinder instance with custom storage
let mut storages = new;
storages.insert;
let vue_finder = VueFinder ;
// Use VueFinder methods directly
vue_finder.list_contents.await?;
Configuration
VueFinder supports configuration through a JSON file. By default, it looks for vuefinder.json
in the current directory.
You can specify a custom config file path using the -c
or --config
option:
Example configuration file:
Command Line Options
-p, --port <PORT>
: Specify server port [default: 8080]-b, --host <HOST>
: Specify binding address [default: 127.0.0.1]-l, --local-storage <PATH>
: Specify local storage path [default: ./storage]-c, --config <PATH>
: Specify configuration file path [default: ./vuefinder.json]
# Examples
Features
- File operations: upload, download, delete, rename, move
- Directory operations: create, list, delete
- Archive operations: zip, unzip
- Multiple storage adapters support
- Large file support (up to 100MB by default)
- Configurable API endpoints and limits
License
This project is licensed under the MIT License - see the LICENSE file for details.