152 lines
4.8 KiB
TOML
152 lines
4.8 KiB
TOML
[workspace]
|
|
members = [
|
|
".",
|
|
"crates/smolvm-agent",
|
|
"crates/smolvm-cuda",
|
|
"crates/smolvm-cuda-guest",
|
|
"crates/smolvm-cuda-shim",
|
|
"crates/smolvm-cuda-codegen",
|
|
"crates/smolvm-cudart-shim",
|
|
"crates/smolvm-network",
|
|
"crates/smolvm-pack",
|
|
"crates/smolvm-protocol",
|
|
"crates/smolvm-registry",
|
|
"crates/smolvm-smolfile",
|
|
]
|
|
resolver = "2"
|
|
|
|
[package]
|
|
name = "smolvm"
|
|
version = "1.5.2"
|
|
edition = "2021"
|
|
description = "OCI-native microVM runtime"
|
|
license = "Apache-2.0"
|
|
repository = "https://github.com/smol-machines/smolvm"
|
|
keywords = ["microvm", "container", "virtualization"]
|
|
categories = ["virtualization", "command-line-utilities"]
|
|
|
|
[lib]
|
|
name = "smolvm"
|
|
path = "src/lib.rs"
|
|
|
|
[[bin]]
|
|
name = "smolvm"
|
|
path = "src/main.rs"
|
|
|
|
[dependencies]
|
|
smolvm-network = { path = "crates/smolvm-network", version = "1.5.2" }
|
|
smolvm-protocol = { path = "crates/smolvm-protocol", version = "1.5.2" }
|
|
smolvm-cuda = { path = "crates/smolvm-cuda", version = "1.5.2" }
|
|
smolvm-pack = { path = "crates/smolvm-pack", version = "1.5.2" }
|
|
smolvm-registry = { path = "crates/smolvm-registry", version = "1.5.2" }
|
|
smolfile = { path = "crates/smolvm-smolfile", version = "1.5.2" }
|
|
thiserror = "1"
|
|
clap = { version = "4", features = ["derive"] }
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
serde_yaml = "0.9"
|
|
toml = "0.8"
|
|
rusqlite = { version = "0.32", features = ["bundled"] }
|
|
libc = "0.2"
|
|
# Cross-platform dynamic library loading for libkrun (dlopen on Unix,
|
|
# LoadLibraryW on Windows). Replaces the previous direct libc::dlopen path.
|
|
libloading = "0.8"
|
|
# Cross-platform AF_UNIX sockets for the agent control channel and vsock-port
|
|
# bridges. std has no UnixStream on Windows, but socket2 (Domain::UNIX) works
|
|
# on Windows 10 1809+. See src/platform/uds.rs.
|
|
socket2 = "0.6"
|
|
dirs = "5"
|
|
sha2 = "0.10"
|
|
hex = "0.4"
|
|
# Host filesystem watcher (FSEvents on macOS, inotify on Linux) that drives
|
|
# host→guest fsnotify propagation for -v mounts. See src/agent/fsnotify_watch.rs.
|
|
notify = "6"
|
|
tracing = "0.1"
|
|
tracing-subscriber = { version = "0.3", features = ["json", "env-filter"] }
|
|
|
|
base64 = { workspace = true }
|
|
|
|
# Secrets management. Resolved plaintext is scrubbed on drop; smolvm stores no
|
|
# secret material itself (refs only), so no at-rest crypto/store deps are needed.
|
|
zeroize = { version = "1", features = ["zeroize_derive"] }
|
|
humantime = "2"
|
|
tempfile = "3"
|
|
|
|
# HTTP API server
|
|
tokio = { version = "1", features = ["full"] }
|
|
axum = { version = "0.8", features = ["macros", "ws"] }
|
|
# mTLS for the fleet serve API (control↔node). axum-server's rustls acceptor
|
|
# does the TLS handshake + client-cert verification; rustls-pemfile parses the
|
|
# CA/cert/key PEMs handed to us at enrollment.
|
|
axum-server = { version = "0.7", features = ["tls-rustls"] }
|
|
rustls = { version = "0.23", default-features = false, features = ["ring"] }
|
|
rustls-pemfile = "2"
|
|
rustls-pki-types = "1"
|
|
tower-http = { version = "0.6", features = ["cors", "trace", "timeout"] }
|
|
tokio-stream = "0.1"
|
|
# ReaderStream for streaming a cached blob from disk to a peer (GET /p2p/blob).
|
|
tokio-util = { version = "0.7", features = ["io"] }
|
|
parking_lot = "0.12"
|
|
async-stream = "0.3"
|
|
futures-util = "0.3"
|
|
|
|
# OpenAPI documentation
|
|
utoipa = { version = "5", features = ["axum_extras"] }
|
|
utoipa-axum = "0.2"
|
|
utoipa-swagger-ui = { version = "9", features = ["axum", "vendored"] }
|
|
ipnet = "2.12.0"
|
|
metrics = "0.24"
|
|
|
|
metrics-exporter-prometheus = { version = "0.16", default-features = false }
|
|
|
|
# Seccomp + Landlock for the VM boot subprocess (runtime isolation). Linux-only
|
|
# — macOS/HVF has neither; the code is cfg-gated to linux (seccomp also to x86_64).
|
|
[target.'cfg(target_os = "linux")'.dependencies]
|
|
seccompiler = "0.4"
|
|
landlock = "0.4"
|
|
|
|
# Windows process management (OpenProcess / TerminateProcess / Wait) and
|
|
# DLL-search-path control (SetDllDirectoryW). Used to replace the Unix
|
|
# kill/waitpid/dlopen primitives on the Windows host build.
|
|
[target.'cfg(windows)'.dependencies]
|
|
windows-sys = { version = "0.60", features = [
|
|
"Win32_Foundation",
|
|
"Win32_System_Threading",
|
|
"Win32_System_ProcessStatus",
|
|
"Win32_System_LibraryLoader",
|
|
"Win32_System_Console",
|
|
"Win32_System_IO",
|
|
"Win32_Storage_FileSystem",
|
|
"Win32_Networking_WinSock",
|
|
] }
|
|
|
|
[dev-dependencies]
|
|
tempfile = "3"
|
|
smolvm-protocol = { path = "crates/smolvm-protocol", version = "1.5.2" }
|
|
regex = "1"
|
|
|
|
[build-dependencies]
|
|
pkg-config = "0.3"
|
|
|
|
[workspace.dependencies]
|
|
base64 = "0.22"
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
thiserror = "1"
|
|
tracing = "0.1"
|
|
|
|
# Release profile optimizations
|
|
[profile.release]
|
|
lto = true
|
|
codegen-units = 1
|
|
strip = true
|
|
|
|
# Smaller binary profile for agent (use with --profile release-small)
|
|
[profile.release-small]
|
|
inherits = "release"
|
|
opt-level = "z" # Optimize for size
|
|
lto = true
|
|
codegen-units = 1
|
|
panic = "abort" # No unwinding - saves ~10% binary size
|
|
strip = true
|