distributed file system based on kademlia dht
Project description
Distributed file system based on https://github.com/bmuller/kademlia for the final project of distributed systems
Documentation
https://geekslabtech.github.io/kade-drive/
Basic Usage
- Clone the repo and run
poetry install
- Run
poetry run server
in one pc or several pc in a local network - Run
poetry run cli
in any pc of the network and start playing with the system
Usage with docker
- Build the image with
make docker
- Run
make shell
to start the Docker container with an interactive Bash shell - Now you can run
poetry run server
to start a server orpoetry run cli
Installation
pip install kade-drive
Server
from kade_drive.server import start_server
start_server()
Client
Note: Make sure that there exist at least a server in the local network
from kade_drive.cli import ClientSession
client = ClientSession()
client.connect()
response, _ = client.put(4, 5)
# If true, it means that the value was setted correctly, false otherwise
assert response is True
value, _ = client.get(4)
assert value == 5
Tests
To run tests make shure that there is at least one server in the network.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
kade_drive-0.7.0.tar.gz
(26.1 kB
view details)
Built Distribution
File details
Details for the file kade_drive-0.7.0.tar.gz
.
File metadata
- Download URL: kade_drive-0.7.0.tar.gz
- Upload date:
- Size: 26.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.3.1 CPython/3.11.3 Linux/6.2.15-300.fc38.x86_64
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cba0b0642607be9e792be589e8fc5bb9cb495ea488cb8a6eda437b3c81487186 |
|
MD5 | b936ec544dd70dfc43d29db42ccf311c |
|
BLAKE2b-256 | 23b1e08805509b7e9244c5e38756136f03c76a9cce58b06ca5a2bf9a7269f956 |
File details
Details for the file kade_drive-0.7.0-py3-none-any.whl
.
File metadata
- Download URL: kade_drive-0.7.0-py3-none-any.whl
- Upload date:
- Size: 31.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.3.1 CPython/3.11.3 Linux/6.2.15-300.fc38.x86_64
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8ed8aac945fece4f2e004d3411edab43e4afac02167c692fc622184be97abaab |
|
MD5 | 1cb7130cc85c61e96bbccd8d919f42f7 |
|
BLAKE2b-256 | f4bd21b797ce71fd254ddb6ec97c561ebe757a845ed5262eb7377b2f17bf2502 |