build(rust): declare rust-version 1.88; rustup setup for the server
CI / Format & lint (push) Successful in 24s
CI / Test suite (push) Successful in 44s
Rust / fmt, clippy, test, build (push) Successful in 9m50s

This commit is contained in:
grabowski committed 2026-10-17 22:39:45 +07:00
1 parent 4e619aa2ae
commit 63353f1e80
4 files changed
+19 -5

No files matched your search

+13 -4
View File
@@ -72,12 +72,21 @@ Linux needs `pkg-config` and `libssl-dev`.
### Deploy
On the server, after `git pull` (the Python side of the switch ships in the
same commit):
Needs Rust >= 1.88. Distro `cargo` packages are older (`resolver 3 is not
valid` / `edition 2024` errors), so install the toolchain once with rustup:
```bash
cargo build --release --locked --manifest-path rust/Cargo.toml # as a normal user,
# or BIN=<CI artifact>
apt-get install -y build-essential pkg-config libssl-dev curl
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal
. "$HOME/.cargo/env" # puts ~/.cargo/bin before /usr/bin/cargo
cargo --version # >= 1.88
```
Then on the server, after `git pull` (the Python side of the switch ships in
the same commit):
```bash
cargo build --release --locked --manifest-path rust/Cargo.toml # or BIN=<CI artifact>
sudo bash scripts/install_collector.sh # install + dry run, nothing switched
sudo bash scripts/install_collector.sh --cutover # Rust collects from now on
sudo bash scripts/install_collector.sh --rollback # back to Python collection