Full migration and transition to Rust; Remove python artifacts
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
logs
|
||||
data
|
||||
tmp
|
||||
myfsio-engine/target
|
||||
myfsio-engine/tests
|
||||
target
|
||||
crates/*/tests
|
||||
Dockerfile
|
||||
.dockerignore
|
||||
6
.gitignore
vendored
6
.gitignore
vendored
@@ -26,12 +26,8 @@ dist/
|
||||
*.egg-info/
|
||||
.eggs/
|
||||
|
||||
# Rust / maturin build artifacts
|
||||
python/myfsio_core/target/
|
||||
python/myfsio_core/Cargo.lock
|
||||
|
||||
# Rust engine build artifacts
|
||||
rust/myfsio-engine/target/
|
||||
target/
|
||||
|
||||
# Local runtime artifacts
|
||||
logs/
|
||||
|
||||
0
rust/myfsio-engine/Cargo.lock → Cargo.lock
generated
0
rust/myfsio-engine/Cargo.lock → Cargo.lock
generated
@@ -6,10 +6,10 @@ RUN apt-get update \
|
||||
&& apt-get install -y --no-install-recommends build-essential pkg-config libssl-dev \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
COPY myfsio-engine ./myfsio-engine
|
||||
COPY Cargo.toml Cargo.lock ./
|
||||
COPY crates ./crates
|
||||
|
||||
RUN cd myfsio-engine \
|
||||
&& cargo build --release --bin myfsio-server \
|
||||
RUN cargo build --release --bin myfsio-server \
|
||||
&& strip target/release/myfsio-server
|
||||
|
||||
|
||||
@@ -24,9 +24,9 @@ RUN apt-get update \
|
||||
&& useradd -m -u 1000 myfsio \
|
||||
&& chown -R myfsio:myfsio /app
|
||||
|
||||
COPY --from=builder /build/myfsio-engine/target/release/myfsio-server /usr/local/bin/myfsio-server
|
||||
COPY --from=builder /build/myfsio-engine/crates/myfsio-server/templates /app/templates
|
||||
COPY --from=builder /build/myfsio-engine/crates/myfsio-server/static /app/static
|
||||
COPY --from=builder /build/target/release/myfsio-server /usr/local/bin/myfsio-server
|
||||
COPY --from=builder /build/crates/myfsio-server/templates /app/templates
|
||||
COPY --from=builder /build/crates/myfsio-server/static /app/static
|
||||
COPY docker-entrypoint.sh /app/docker-entrypoint.sh
|
||||
|
||||
RUN chmod +x /app/docker-entrypoint.sh \
|
||||
21
README.md
21
README.md
@@ -1,8 +1,6 @@
|
||||
# MyFSIO
|
||||
|
||||
MyFSIO is an S3-compatible object storage server with a Rust runtime and a filesystem-backed storage engine. The active server lives under `rust/myfsio-engine` and serves both the S3 API and the built-in web UI from a single process.
|
||||
|
||||
The `python/` implementation is deprecated as of 2026-04-21. It remains in the repository for migration reference and legacy tests, but new development and supported runtime usage should target the Rust server.
|
||||
MyFSIO is an S3-compatible object storage server with a Rust runtime and a filesystem-backed storage engine. The repository root is the Cargo workspace; the server serves both the S3 API and the built-in web UI from a single process.
|
||||
|
||||
## Features
|
||||
|
||||
@@ -29,7 +27,6 @@ If you want API-only mode, set `UI_ENABLED=false`. There is no separate "UI-only
|
||||
From the repository root:
|
||||
|
||||
```bash
|
||||
cd rust/myfsio-engine
|
||||
cargo run -p myfsio-server --
|
||||
```
|
||||
|
||||
@@ -60,14 +57,13 @@ UI_ENABLED=false cargo run -p myfsio-server --
|
||||
## Building a Binary
|
||||
|
||||
```bash
|
||||
cd rust/myfsio-engine
|
||||
cargo build --release -p myfsio-server
|
||||
```
|
||||
|
||||
Binary locations:
|
||||
|
||||
- Linux/macOS: `rust/myfsio-engine/target/release/myfsio-server`
|
||||
- Windows: `rust/myfsio-engine/target/release/myfsio-server.exe`
|
||||
- Linux/macOS: `target/release/myfsio-server`
|
||||
- Windows: `target/release/myfsio-server.exe`
|
||||
|
||||
Run the built binary directly:
|
||||
|
||||
@@ -166,10 +162,10 @@ data/
|
||||
|
||||
## Docker
|
||||
|
||||
Build the Rust image from the `rust/` directory:
|
||||
Build the Rust image from the repository root:
|
||||
|
||||
```bash
|
||||
docker build -t myfsio ./rust
|
||||
docker build -t myfsio .
|
||||
docker run --rm -p 5000:5000 -p 5100:5100 -v "${PWD}/data:/app/data" myfsio
|
||||
```
|
||||
|
||||
@@ -180,11 +176,9 @@ If the instance sits behind a reverse proxy, set `API_BASE_URL` to the public S3
|
||||
The repository includes `scripts/install.sh` for systemd-style Linux installs. Build the Rust binary first, then pass it to the installer:
|
||||
|
||||
```bash
|
||||
cd rust/myfsio-engine
|
||||
cargo build --release -p myfsio-server
|
||||
|
||||
cd ../..
|
||||
sudo ./scripts/install.sh --binary ./rust/myfsio-engine/target/release/myfsio-server
|
||||
sudo ./scripts/install.sh --binary ./target/release/myfsio-server
|
||||
```
|
||||
|
||||
The installer copies the binary into `/opt/myfsio/myfsio`, writes `/opt/myfsio/myfsio.env`, and can register a `myfsio.service` unit.
|
||||
@@ -194,7 +188,6 @@ The installer copies the binary into `/opt/myfsio/myfsio`, writes `/opt/myfsio/m
|
||||
Run the Rust test suite from the workspace:
|
||||
|
||||
```bash
|
||||
cd rust/myfsio-engine
|
||||
cargo test
|
||||
```
|
||||
|
||||
@@ -209,4 +202,4 @@ cargo test
|
||||
}
|
||||
```
|
||||
|
||||
The `version` field comes from the Rust crate version in `rust/myfsio-engine/crates/myfsio-server/Cargo.toml`.
|
||||
The `version` field comes from the Rust crate version in `crates/myfsio-server/Cargo.toml`.
|
||||
|
||||
|
Before Width: | Height: | Size: 200 KiB After Width: | Height: | Size: 200 KiB |
|
Before Width: | Height: | Size: 872 KiB After Width: | Height: | Size: 872 KiB |
@@ -73,16 +73,13 @@
|
||||
</div>
|
||||
<p class="text-muted">Build or run the Rust server and launch the API plus web UI from a single process.</p>
|
||||
<div class="alert alert-light border small mb-3">
|
||||
Runtime note: MyFSIO now runs from the Rust server in <code>rust/myfsio-engine</code>. For the verified runtime configuration list, use the repository <code>docs.md</code>.
|
||||
Runtime note: the repository root is the Cargo workspace. For the verified runtime configuration list, use the repository <code>docs.md</code>.
|
||||
</div>
|
||||
<ol class="docs-steps">
|
||||
<li>Install a current Rust toolchain.</li>
|
||||
<li>Change into <code>rust/myfsio-engine</code>.</li>
|
||||
<li>Start the server with <code>cargo run -p myfsio-server --</code>.</li>
|
||||
<li>From the repository root, start the server with <code>cargo run -p myfsio-server --</code>.</li>
|
||||
</ol>
|
||||
<pre class="mb-3"><code class="language-bash">cd rust/myfsio-engine
|
||||
|
||||
# Run API + UI
|
||||
<pre class="mb-3"><code class="language-bash"># Run API + UI
|
||||
cargo run -p myfsio-server --
|
||||
|
||||
# Show resolved configuration
|
||||
34
docs.md
34
docs.md
@@ -1,26 +1,19 @@
|
||||
# MyFSIO Rust Operations Guide
|
||||
|
||||
This document describes the current Rust server in `rust/myfsio-engine`. It replaces the older Python-oriented runbook.
|
||||
This document describes the MyFSIO Rust server. The repository root is the Cargo workspace.
|
||||
|
||||
The `python/` implementation is deprecated as of 2026-04-21. It is retained for migration reference and legacy validation only; production usage and new development should use the Rust server.
|
||||
|
||||
## 1. What Changed
|
||||
|
||||
The active runtime is now Rust:
|
||||
## 1. Overview
|
||||
|
||||
- One process serves both the S3 API and the web UI.
|
||||
- The server entrypoint is `myfsio-server`.
|
||||
- The main development workflow is `cargo run -p myfsio-server --`.
|
||||
- API-only mode is controlled with `UI_ENABLED=false`.
|
||||
|
||||
The deprecated `python/` directory may still contain older implementation code, templates, and tests, but it is not required to run the current server.
|
||||
|
||||
## 2. Quick Start
|
||||
|
||||
From the repository root:
|
||||
|
||||
```bash
|
||||
cd rust/myfsio-engine
|
||||
cargo run -p myfsio-server --
|
||||
```
|
||||
|
||||
@@ -34,10 +27,9 @@ On first startup, MyFSIO bootstraps an admin user in `data/.myfsio.sys/config/ia
|
||||
|
||||
### Windows
|
||||
|
||||
From PowerShell:
|
||||
From PowerShell at the repository root:
|
||||
|
||||
```powershell
|
||||
cd rust\myfsio-engine
|
||||
cargo run -p myfsio-server --
|
||||
```
|
||||
|
||||
@@ -52,7 +44,6 @@ There is no separate UI-only mode in the Rust server.
|
||||
## 3. Build and Run a Binary
|
||||
|
||||
```bash
|
||||
cd rust/myfsio-engine
|
||||
cargo build --release -p myfsio-server
|
||||
```
|
||||
|
||||
@@ -104,7 +95,7 @@ That makes local development and systemd installs behave consistently.
|
||||
|
||||
## 6. Verified Configuration Reference
|
||||
|
||||
These values are taken from `rust/myfsio-engine/crates/myfsio-server/src/config.rs`.
|
||||
These values are taken from `crates/myfsio-server/src/config.rs`.
|
||||
|
||||
### Network and runtime
|
||||
|
||||
@@ -311,10 +302,10 @@ Notes:
|
||||
|
||||
## 10. Docker
|
||||
|
||||
Build the Rust image from the `rust/` directory:
|
||||
Build the Rust image from the repository root:
|
||||
|
||||
```bash
|
||||
docker build -t myfsio ./rust
|
||||
docker build -t myfsio .
|
||||
docker run --rm \
|
||||
-p 5000:5000 \
|
||||
-p 5100:5100 \
|
||||
@@ -337,11 +328,9 @@ If you want generated links and presigned URLs to use an external hostname, set
|
||||
The repository includes `scripts/install.sh`. For the Rust server, build the binary first and pass the path explicitly:
|
||||
|
||||
```bash
|
||||
cd rust/myfsio-engine
|
||||
cargo build --release -p myfsio-server
|
||||
|
||||
cd ../..
|
||||
sudo ./scripts/install.sh --binary ./rust/myfsio-engine/target/release/myfsio-server
|
||||
sudo ./scripts/install.sh --binary ./target/release/myfsio-server
|
||||
```
|
||||
|
||||
The installer copies that binary to `/opt/myfsio/myfsio`, creates `/opt/myfsio/myfsio.env`, and can register a `myfsio.service` systemd unit.
|
||||
@@ -396,14 +385,13 @@ The command:
|
||||
Run the Rust test suite:
|
||||
|
||||
```bash
|
||||
cd rust/myfsio-engine
|
||||
cargo test
|
||||
```
|
||||
|
||||
If you are validating documentation changes for the UI, the most relevant coverage lives under:
|
||||
|
||||
- `rust/myfsio-engine/crates/myfsio-server/tests`
|
||||
- `rust/myfsio-engine/crates/myfsio-storage/src`
|
||||
- `crates/myfsio-server/tests`
|
||||
- `crates/myfsio-storage/src`
|
||||
|
||||
## 15. API Notes
|
||||
|
||||
@@ -417,5 +405,5 @@ The Rust server exposes:
|
||||
|
||||
For a route-level view, inspect:
|
||||
|
||||
- `rust/myfsio-engine/crates/myfsio-server/src/lib.rs`
|
||||
- `rust/myfsio-engine/crates/myfsio-server/src/handlers/`
|
||||
- `crates/myfsio-server/src/lib.rs`
|
||||
- `crates/myfsio-server/src/handlers/`
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user