diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index be2ce07..16e9ed2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,6 +12,23 @@ env: RUSTFLAGS: "-D warnings" jobs: + deny: + runs-on: ubuntu-latest + env: + CARGO_DENY_VERSION: "0.19.6" + steps: + - uses: actions/checkout@v4 + + - name: Install Rust toolchain + uses: dtolnay/rust-toolchain@stable + + - name: Install cargo-deny + run: | + curl -sL "https://github.com/EmbarkStudios/cargo-deny/releases/download/${CARGO_DENY_VERSION}/cargo-deny-${CARGO_DENY_VERSION}-x86_64-unknown-linux-musl.tar.gz" | tar xz -C /usr/local/bin --strip-components=1 + + - name: Check dependencies + run: cargo deny check + build-and-test: runs-on: ubuntu-latest steps: diff --git a/Cargo.lock b/Cargo.lock index 812e80c..4b69ed9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -75,7 +75,7 @@ version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "40c48f72fd53cd289104fc64099abca73db4166ad86ea0b4341abe65af83dadc" dependencies = [ - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -86,7 +86,7 @@ checksum = "291e6a250ff86cd4a820112fb8898808a366d8f9f58ce16d1f538353ad55747d" dependencies = [ "anstyle", "once_cell_polyfill", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -264,7 +264,7 @@ checksum = "b62ddb9cb1ec0a098ad4bbf9344d0713fa193ae1a80af55febcff2627b6a00c1" dependencies = [ "getrandom 0.2.17", "instant", - "rand 0.8.5", + "rand 0.8.6", ] [[package]] @@ -666,7 +666,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" dependencies = [ "libc", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -1474,7 +1474,7 @@ dependencies = [ "k8s-openapi", "kube-core", "pem", - "rand 0.8.5", + "rand 0.8.6", "rustls", "rustls-pemfile", "secrecy", @@ -1708,7 +1708,7 @@ version = "0.50.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7957b9740744892f114936ab4a57b3f487491bbeafaf8083688b16841a4240e5" dependencies = [ - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -1732,7 +1732,7 @@ dependencies = [ "num-integer", "num-iter", "num-traits", - "rand 0.8.5", + "rand 0.8.6", "smallvec", "zeroize", ] @@ -2107,7 +2107,7 @@ dependencies = [ "bytes", "getrandom 0.3.4", "lru-slab", - "rand 0.9.3", + "rand 0.9.4", "ring", "rustc-hash", "rustls", @@ -2156,9 +2156,9 @@ checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf" [[package]] name = "rand" -version = "0.8.5" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +checksum = "5ca0ecfa931c29007047d1bc58e623ab12e5590e8c7cc53200d5202b69266d8a" dependencies = [ "libc", "rand_chacha 0.3.1", @@ -2167,9 +2167,9 @@ dependencies = [ [[package]] name = "rand" -version = "0.9.3" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ec095654a25171c2124e9e3393a930bddbffdc939556c914957a4c3e0a87166" +checksum = "44c5af06bb1b7d3216d91932aed5265164bf384dc89cd6ba05cf59a35f5f76ea" dependencies = [ "rand_chacha 0.9.0", "rand_core 0.9.5", @@ -2348,14 +2348,14 @@ dependencies = [ "errno", "libc", "linux-raw-sys", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] name = "rustls" -version = "0.23.37" +version = "0.23.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "758025cb5fccfd3bc2fd74708fd4682be41d99e5dff73c377c0646c6012c73a4" +checksum = "ef86cd5876211988985292b91c96a8f2d298df24e75989a43a3c73f2d4d8168b" dependencies = [ "log", "once_cell", @@ -2412,9 +2412,9 @@ dependencies = [ [[package]] name = "rustls-webpki" -version = "0.103.11" +version = "0.103.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20a6af516fea4b20eccceaf166e8aa666ac996208e8a644ce3ef5aa783bc7cd4" +checksum = "61c429a8649f110dddef65e2a5ad240f747e85f7758a6bccc7e5777bd33f756e" dependencies = [ "ring", "rustls-pki-types", @@ -2733,7 +2733,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3a766e1110788c36f4fa1c2b71b387a7815aa65f88ce0229841826633d93723e" dependencies = [ "libc", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -2773,7 +2773,7 @@ dependencies = [ "kube", "prost", "prost-types", - "rand 0.8.5", + "rand 0.8.6", "reqwest", "schemars", "semver", @@ -2935,7 +2935,7 @@ dependencies = [ "memchr", "once_cell", "percent-encoding", - "rand 0.8.5", + "rand 0.8.6", "rsa", "serde", "sha1", @@ -2975,7 +2975,7 @@ dependencies = [ "md-5", "memchr", "once_cell", - "rand 0.8.5", + "rand 0.8.6", "serde", "serde_json", "sha2", @@ -3081,10 +3081,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd" dependencies = [ "fastrand", - "getrandom 0.3.4", + "getrandom 0.4.2", "once_cell", "rustix", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -3363,7 +3363,7 @@ dependencies = [ "indexmap 1.9.3", "pin-project", "pin-project-lite", - "rand 0.8.5", + "rand 0.8.6", "slab", "tokio", "tokio-util", @@ -3532,7 +3532,7 @@ dependencies = [ "http", "httparse", "log", - "rand 0.8.5", + "rand 0.8.6", "sha1", "thiserror 1.0.69", "utf-8", diff --git a/Cargo.toml b/Cargo.toml index 965942f..3c5fc9c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,6 +9,7 @@ members = [ version = "0.3.0" edition = "2021" license = "Apache-2.0" +publish = false repository = "https://github.com/ROCm/spur-cloud" [workspace.dependencies] @@ -67,7 +68,7 @@ futures-util = "0.3" bytes = "1" url = "2" base64 = "0.22" -rand = "0.8" +rand = "0.8.6" sha2 = "0.10" semver = "1" diff --git a/crates/spur-cloud-api/Cargo.toml b/crates/spur-cloud-api/Cargo.toml index 0bfa353..28973df 100644 --- a/crates/spur-cloud-api/Cargo.toml +++ b/crates/spur-cloud-api/Cargo.toml @@ -2,6 +2,8 @@ name = "spur-cloud-api" version.workspace = true edition.workspace = true +license.workspace = true +publish.workspace = true [[bin]] name = "spur-cloud-api" diff --git a/crates/spur-cloud-common/Cargo.toml b/crates/spur-cloud-common/Cargo.toml index b9c52bd..cd414f4 100644 --- a/crates/spur-cloud-common/Cargo.toml +++ b/crates/spur-cloud-common/Cargo.toml @@ -2,6 +2,8 @@ name = "spur-cloud-common" version.workspace = true edition.workspace = true +license.workspace = true +publish.workspace = true [dependencies] serde.workspace = true diff --git a/deny.toml b/deny.toml new file mode 100644 index 0000000..d80f332 --- /dev/null +++ b/deny.toml @@ -0,0 +1,43 @@ +[graph] +all-features = true + +[advisories] +yanked = "warn" +unmaintained = "workspace" + +[licenses] +confidence-threshold = 0.8 + +allow = [ + "MIT", + "Apache-2.0", + "Apache-2.0 WITH LLVM-exception", + "BSD-2-Clause", + "BSD-3-Clause", + "ISC", + "Unicode-3.0", + "Zlib", + "BSL-1.0", + "Unlicense", + "CDLA-Permissive-2.0", +] + +# Git-sourced spur-proto uses license.workspace = true; synthesized manifest has no license field. +[[licenses.clarify]] +name = "spur-proto" +expression = "Apache-2.0" +license-files = [ + { path = "../../LICENSE", hash = 0x001c7e6c }, +] + +[bans] +multiple-versions = "warn" +wildcards = "deny" +allow-wildcard-paths = true + +[sources] +unknown-registry = "deny" +unknown-git = "deny" +allow-git = [ + "https://github.com/ROCm/spur", +]