https://github.com/golemfactory/ya-vm-file-server
Cross-platform 9p file server implemented in Rust.
https://github.com/golemfactory/ya-vm-file-server
Last synced: 6 months ago
JSON representation
Cross-platform 9p file server implemented in Rust.
- Host: GitHub
- URL: https://github.com/golemfactory/ya-vm-file-server
- Owner: golemfactory
- License: bsd-3-clause
- Created: 2022-03-09T10:05:11.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2023-10-16T06:32:53.000Z (about 2 years ago)
- Last Synced: 2025-04-05T06:31:44.536Z (9 months ago)
- Language: Rust
- Size: 102 KB
- Stars: 2
- Watchers: 4
- Forks: 4
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## ya-vm-file-server
Cross-platform 9p file server implemented in Rust/Tokio.
The work is based on:
https://github.com/pfpacket/rust-9p
Author of original implementation: Ryo Munakata
## why separate project
We have to fork this library to enable cross-platform capabilities of p9 server.
Original implementation worked only of Linux filesystem.
* Emulating unix attributes
* Maximum separation between server filesystem and client filesystem
* Similar behavior when served on Linux and Windows machine.
## Build
To compile only library part:
```bash
cargo build
```
To compile binary:
```bash
cargo build --bin ya-vm-file-server --features="build-binary debug-msg"
```
## Testing
Build docker:
```
docker build . -t ya-vm-file-server
```
Running docker tests
```
docker-compose up
```
### Integration tests
Tests are half-automatic. First you need to prepare an environment:
1) Launch 9p server:
```
RUST_LOG=debug cargo run --features="build-binary" -- --mount-point tests/9p_mnt_point
```
3) On other shell mount to the server:
```
cd tests
sudo mount -t 9p -o version=9p2000.L,trans=tcp,debug=0x04,port=7878,uname=testuser 127.0.0.1 ./mnt_tests
```
4) Launch tests using **nightly** build:
```
cargo +nightly test
```
You should be able to see logging on the server side while tests are running.
## Licence
Keeping original implementation licence BSD-3