Skip to content

Commit

Permalink
Use cargo-deny to prevent extra crates being pulled into the build ba…
Browse files Browse the repository at this point in the history
…ckend
  • Loading branch information
konstin committed Feb 13, 2025
1 parent 07bc98a commit 6fff5b2
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/build-binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ jobs:
with:
target: ${{ matrix.target }}
manylinux: auto
args: --profile minimal-size --locked --out dist --features self-update
args: --release --locked --out dist --features self-update
# See: https://github.com/sfackler/rust-openssl/issues/2036#issuecomment-1724324145
before-script-linux: |
# If we're running on rhel centos, install needed packages.
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,10 @@ jobs:
- uses: Swatinem/rust-cache@v2
with:
save-if: ${{ github.ref == 'refs/heads/main' }}
- uses: EmbarkStudios/cargo-deny-action@v1
command: check bans
with:
manifest-path: crates/uv-build/Cargo.toml
- name: "Install Rust toolchain"
run: rustup component add clippy
- name: "Clippy"
Expand Down
8 changes: 8 additions & 0 deletions crates/uv-build/deny.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
[bans]
multiple-versions = "allow"
deny = [
{ crate = "rustls", reason = "The build backend does not need network access" },
{ crate = "openssl", reason = "The build backend does not need network access" },
{ crate = "reqwest", reason = "The build backend does not need network access" },
{ crate = "schemars", reason = "JSON Schema generation is a development feature, not a runtime feature" },
]

0 comments on commit 6fff5b2

Please sign in to comment.