Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lychee/0.15.1-r3: cve remediation #36217

Closed
wants to merge 2 commits into from

Conversation

octo-sts[bot]
Copy link
Contributor

@octo-sts octo-sts bot commented Dec 10, 2024

Copy link
Contributor Author

octo-sts bot commented Dec 10, 2024

Gen AI suggestions to solve the build error:

Based on the build log and Melange YAML file, let me analyze the error and provide a solution:

• Detected Error: No explicit error message is shown, but the build appears to fail silently after installing dependencies

• Error Category: Dependency/Configuration

• Failure Point: The build environment setup completes, but the actual build doesn't seem to start

• Root Cause Analysis: The package requires Rust 1.74.0 or newer (based on lychee v0.15.1 requirements), but the YAML specifies rust-1.83 which appears to resolve to 1.83.0

• Suggested Fix:
Update the environment section to explicitly specify the Rust version:

environment:
  contents:
    packages:
      - build-base
      - busybox
      - ca-certificates-bundle
      - cargo-auditable
      - openssf-compiler-options
      - openssl-dev
      - rust-1.74

• Explanation:

  • Lychee 0.15.1 requires a newer version of Rust than what's being installed
  • The current specification allows for an older version to be selected
  • Explicitly specifying rust-1.74 will ensure the correct toolchain is available
  • This matches the package's MSRV (Minimum Supported Rust Version)

• Additional Notes:

  • Consider adding pkg-config to the build dependencies if SSL linking issues occur
  • You may want to add build-time dependencies like cmake if build failures occur after this fix
  • The test section looks good and comprehensive

• References:

Copy link
Contributor Author

octo-sts bot commented Jan 5, 2025

Gen AI suggestions to solve the build error:

Based on the error output and package details, let me analyze this:

• Detected Error: No explicit error is shown in the logs, but the build appears to stop after installing dependencies. This suggests the build is failing silently in the pipeline execution.

• Error Category: Build Configuration

• Failure Point: The Rust build step using cargo auditable

• Root Cause Analysis: The melange configuration is missing a key Rust dependency - the rust toolchain selector. While rust-1.83 is installed, it needs to be explicitly selected.

• Suggested Fix: Add rust-toolchain selection to the environment section:

environment:
  contents:
    packages:
      - build-base
      - busybox
      - ca-certificates-bundle
      - cargo-auditable
      - openssf-compiler-options
      - openssl-dev
      - rust
      - rust-1.83
  environment:
    RUSTUP_TOOLCHAIN: "1.83.0"

• Explanation:

  • Rust builds require an explicit toolchain selection
  • The RUSTUP_TOOLCHAIN environment variable ensures the correct Rust version is used
  • This matches the installed rust-1.83 package version
  • This prevents potential version mismatches during build

• Additional Notes:

  • The package is using cargo auditable which requires a specific Rust version
  • Version 0.15.1 of lychee is compatible with Rust 1.83
  • The environment variable approach is preferred for Wolfi Rust builds

• References:

@Dentrax
Copy link
Member

Dentrax commented Jan 5, 2025

Superseded by: #38813

@Dentrax Dentrax closed this Jan 5, 2025
@Dentrax Dentrax self-assigned this Jan 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant