skyl / corpora

Corpora is a self-building corpus that can help build other arbitrary corpora
GNU Affero General Public License v3.0
2 stars 0 forks source link

feat(static): build openssl for fully static corpora in another arm64 linux container #60

Closed skyl closed 1 day ago

skyl commented 1 day ago

PR Type

enhancement, configuration changes


Description


Changes walkthrough ๐Ÿ“

Relevant files
Enhancement
urls.py
Remove trailing slash from URL pattern in debug mode         

py/packages/corpora_proj/urls.py - Removed trailing slash from the 'bin' path in the URL pattern.
+1/-1     
Configuration changes
Dockerfile.xcompile
Update Dockerfile for static OpenSSL and musl target         

docker/Dockerfile.xcompile
  • Reorganized Dockerfile for building static binaries.
  • Added static OpenSSL build for musl.
  • Updated environment variables for static linking.
  • Added musl target for Rust.
  • +30/-14 

    ๐Ÿ’ก PR-Agent usage: Comment /help "your question" on any pull request to receive relevant information

    github-actions[bot] commented 1 day ago

    PR Reviewer Guide ๐Ÿ”

    Here are some key observations to aid the review process:

    โฑ๏ธ Estimated effort to review: 3 ๐Ÿ”ต๐Ÿ”ต๐Ÿ”ตโšชโšช
    ๐Ÿงช No relevant tests
    ๐Ÿ”’ No security concerns identified
    โšก Recommended focus areas for review

    URL Consistency
    The trailing slash was removed from the 'bin' path in the URL pattern. Ensure this change does not affect any existing functionality or routing logic. Build Configuration
    The Dockerfile has been updated to build OpenSSL statically for musl. Verify that the new build configuration works as expected and does not introduce any issues.
    github-actions[bot] commented 1 day ago

    PR Code Suggestions โœจ

    Explore these optional code suggestions:

    CategorySuggestion                                                                                                                                    Score
    Possible issue
    Verify the OpenSSL installation paths to prevent build issues ___ **Ensure that the OpenSSL installation path is correctly set by verifying that the
    make install_sw command installs files in the expected directories, as incorrect
    paths can lead to build failures.** [docker/Dockerfile.xcompile [21]](https://github.com/skyl/corpora/pull/60/files#diff-94a0d39409439edeb63eb694c48bf3f4a978f6df278ce6a2fd47ee7a04e3874eR21-R21) ```diff -&& make install_sw +&& make install_sw && ls /usr/local/lib && ls /usr/local/include ```
    Suggestion importance[1-10]: 7 Why: The suggestion to verify the OpenSSL installation paths is valuable as it helps ensure that the installation is successful and files are placed in the expected directories, which can prevent potential build failures.
    7
    Verify Rust installation and musl target addition to prevent runtime errors ___ **Add a verification step to ensure that the Rust installation and the addition of the
    musl target are successful, as failures in these steps can lead to runtime errors.** [docker/Dockerfile.xcompile [25]](https://github.com/skyl/corpora/pull/60/files#diff-94a0d39409439edeb63eb694c48bf3f4a978f6df278ce6a2fd47ee7a04e3874eR25-R25) ```diff -RUN curl https://sh.rustup.rs -sSf | sh -s -- -y +RUN curl https://sh.rustup.rs -sSf | sh -s -- -y && rustc --version && rustup target list --installed ```
    Suggestion importance[1-10]: 7 Why: Adding verification steps for Rust installation and musl target addition is beneficial as it ensures these critical components are correctly set up, reducing the risk of runtime errors due to incomplete installations.
    7