[package]
name = "packguard-server"
version.workspace = true
edition.workspace = true
rust-version.workspace = true
license.workspace = true
repository.workspace = true
description = "PackGuard HTTP server: REST API + job runner backing the dashboard."

[dependencies]
packguard-core = { path = "../packguard-core", version = "0.4.0" }
packguard-store = { path = "../packguard-store", version = "0.4.0" }
packguard-policy = { path = "../packguard-policy", version = "0.4.0" }
packguard-intel = { path = "../packguard-intel", version = "0.4.0" }
packguard-actions = { path = "../packguard-actions", version = "0.4.0" }
anyhow = { workspace = true }
thiserror = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
serde_yaml = { workspace = true }
chrono = { workspace = true }
tokio = { workspace = true }
axum = { workspace = true }
tower = { workspace = true }
tower-http = { workspace = true }
ts-rs = { workspace = true }
uuid = { workspace = true }
sha2 = { workspace = true }
tracing = { workspace = true }
futures = { workspace = true }
rust-embed = { workspace = true, optional = true }
mime_guess = { workspace = true, optional = true }

[features]
default = []
# Bake the built Vite bundle into the binary so `packguard ui` serves the
# dashboard without a dev server. Opt-in because embedding adds ~500KB of
# assets + `build.rs` pulls pnpm into the release build path.
ui-embed = ["dep:rust-embed", "dep:mime_guess"]

[build-dependencies]
anyhow = { workspace = true }

[dev-dependencies]
tempfile = { workspace = true }
reqwest = { workspace = true }
