GithubHelp home page GithubHelp logo

Apple M1 (arm64) Support about geodesic HOT 7 CLOSED

dudymas avatar dudymas commented on June 14, 2024 5
Apple M1 (arm64) Support

from geodesic.

Comments (7)

osterman avatar osterman commented on June 14, 2024 3

Apple M1 Support

We've confirmed that Geodesic works on recent versions of OSX on the M1 running as amd64 (not arm64). Docker auto-detects this by default, but otherwise, it’s possible to pass --platform linux/amd64 to docker to force the platform.

from geodesic.

johncblandii avatar johncblandii commented on June 14, 2024 1

I also needed to add DOCKER_BUILD_FLAGS to the Makefile, but ended up moving both out to my ~/.bash_profile so it supported other devices too.

export GEODESIC_DOCKER_EXTRA_ARGS="--platform linux/arm64"
export DOCKER_BUILD_FLAGS="--platform linux/arm64"

from geodesic.

PiotrPalkaSpotOn avatar PiotrPalkaSpotOn commented on June 14, 2024 1

Coming upon a realization that just building an arm64 geodesic image is not enough as the packages are still built for x86 architecture I was able to fix it (by providing ARCH env variable and an update to one package). I build the proper arm64 image and I can see the performance improvement is huge (about 30%). atmos terraform plan... execution that I use the most went down from 2m30s to 1m30s which is significant taking into consideration that I have tens of executions daily (happy to share more metrics if needed).

As I couldn't verify if all packages work properly I can't say it's a complete setup.

I'm also aware how big chunk of work it is on your side to support geodesic arm64 the right way. Since we're using geodesic debian-based as a base image for our custom container I can see the x86 packages are stored in Cloudsmith Debian repo with no arm64 equivalent so far. Also, not all maintainers are having arm64 packages in their Github Releases which makes things even more complicated. I've checked some packages and their x86 versions work in arm64 container. I can't say if it's efficient.

Anyway, knowing the load of work that has to be done I don't expect geodesic to officially support arm64 soon but it's worth to explore as more Macs with Apple Silicon processor gain developers' attention.

from geodesic.

Nuru avatar Nuru commented on June 14, 2024 1

arm64 support is included, starting with Geodesic version 2.0.0

from geodesic.

Nuru avatar Nuru commented on June 14, 2024

@dudymas I understand the need, but simply compiling the Dockerfile for M1 will not be sufficient. Geodesic bundles dozens (hundreds?) of executable binaries and we would have to have M1 versions of all of them available to install. Plus we would need to build (compile and link) Python3 for M1, and right now we would have to do that with qemu, so if qemu is having problems, it likely won't work.

I will leave this feature request open, but expect it will be more than a year before a sufficient infrastructure is in place to enable Geodesic to be delivered for arm64.

from geodesic.

nitrocode avatar nitrocode commented on June 14, 2024

FYI to set the --platform or any additional docker argument, use the following environment variable.

export GEODESIC_DOCKER_EXTRA_ARGS="--platform linux/amd64"

The poor performance of Geodesic on M1 is not specific to Geodesic, but rather a known issue with Docker for Mac. Things to try from @Nuru

  • Check (enable) Preferences -> General -> use gRPC FUSE for file sharing
  • Check (enable) Preferences -> Experimental Features -> Use the new Virtualization Framework
  • Use VMware Fusion to run a Debian VM, and run Geodesic from within the Debian VM

From @mcalhoun you can see improvements via

  • Check (enable) Preferences -> Experimental Features > Enable VirtioFS accelerated directory sharing

from geodesic.

PiotrPalkaSpotOn avatar PiotrPalkaSpotOn commented on June 14, 2024

Let me add my 2 cents to this discussion and share with you my PR with a Dockerfile that I managed to built on my Mac m1. Took me 2 evenings to figure things out and put it together so even if it looks more like a proof of concept it may be a good start for further development. It looks hacky but it works πŸ˜‰

Happy to get your feedback how it can be improved.

from geodesic.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.