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

Disable Rust dependencies while building cryptography for Docker #1611

Conversation

gabriel-milan
Copy link
Contributor

Summary

Fixes ARM builds for Docker (using one of two available approaches, see details below) (related to #1579 and #1606).

Solve the issue: #1579

Changelog

  • Removes Rust dependencies for Python's cryptography package while building Docker image.

What's new?

Due to cryptography's recent dependencies on Rust (pyca/cryptography#5771), Raspberry Pi's arm/v7 platform (among others) became unsupported. In order to fix that, there are currently two available approaches:

  • Disable Rust while building cryptography with the environment variable CRYPTOGRAPHY_DONT_BUILD_RUST=1 (chosen in this case)
    • Keeps cryptography up to date
    • I couldn't really find the downsides of disabling Rust
  • Use an older version of cryptography (2.6.1 works fine for me in other projects)
    • Cryptography is outdated, can lead to security issues

You can see that when I've tried to build it using the Dockerfile I've customized it seems that the build has gone OK but, unfortunately, there's this issue:

Error: buildx call failed with: error: failed to solve: rpc error: code = Unknown desc = docker exporter does not currently support exporting manifest lists

Fortunately, this isn't related to the Docker image itself, but this: docker/buildx#59.

The purpose of this PR is to find out if this change to the Dockerfile is acceptable. If so, I can implement what is missing.

Copy link
Member

@Herklos Herklos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @gabriel-milan good job ! 👍

@GuillaumeDSM
Copy link
Member

I included your commit here #1612 to apply it on an updated branch, thanks a lot @gabriel-milan !

@gabriel-milan
Copy link
Contributor Author

Thank you guys, can't wait to get this up and running on my RPi.

@GuillaumeDSM
Copy link
Member

merged via #1612
we will soon have OctoBot back on armv7 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants