Open mmmmmrob opened 2 years ago
Yeah, it looks like we'll try to download the x64 binaries.
We really only support darwin so that we can test this buildpack locally. Nobody on the team has an M1 yet, so this isn't a big priority, though I'd entertain a PR.
It looks like the bug could be fixed by changing the architecture calculation here:
(It should return darwin-arm64
for M1 macs)
Returning darwin-arm64
to the getPlatform()
fn didn't solve this for me. Are there any other solutions?
This would be really awesome to support multiple platforms. In our use cases specifically M1 and AWS Graviton architectures.
We use heroku buildpacks and can now deploy to AWS Graviton processors. If the buildpack was able to detect
the platform and binary to install that would be incredible 😃
Or perhaps the simplest approach for now would be to set an environment variable like NODE_PLATFORM=linux-arm64
that would pull the node distribution for ARM v8 🚀
NODE_PLATFORM
would then default to the existing platform binary. This would ensure backwards compatability.
Would this work? Any thoughts? @jmorrell @edmorley @joshwlewis 🤔
For those engineers who support Sustainable Engineering 🌞 and Green Software 🌳 this would be a big deal as this would allow engineers to deploy the same code on ARM, while boosting application performance, using less energy and reducing costs. A win-win for all 👏
Describe the bug The buildpack fails while attempting to install node when running in docker on apple silicon.
The expected behaviour is that the binaries install correctly.
To Reproduce Steps to reproduce the behavior: On an apple silicon machine with docker desktop installed:
.txt
extensiondocker build . --platform=linux/amd64
Versions (please complete the following information):
Yarn 1.22.10
]Additional context Running heroku:20 and the buildpack in docker to create heroku-like runtime environment for local dev.
.