GoogleCloudPlatform / cloud-code-vscode

Cloud Code for Visual Studio Code: Issues, Documentation and more
Other
413 stars 111 forks source link

arm64 for apigee emulator #556

Open lukad opened 2 years ago

lukad commented 2 years ago

Use case It's impossible to develop Apigee proxies on an M1 Macbook because the apigee emulator Docker image has no arm64 support.

Feature arm64 support for the apigee emulator

glouischandra commented 2 years ago

Hello @shirishtrivikr, can you advise here?

shirishtrivikr commented 2 years ago

@lukad Have you tried using the workaround posted here

lukad commented 2 years ago

@shirishtrivikr Interesting, I hadn't seen that issue you linked. But unfortunately that's not really a workaround. That command will run the exact same docker image that the vscode plugin is running which is still amd64. Amd64 images can be run on an M1 processor but will be emulated using QEmu and have awful performance.

imesh commented 2 years ago

Docker has done an improvement to resolve this performance issue by using virtiofs (https://virtio-fs.gitlab.io/) and by improving the way that files are synced between the macOS host and Docker VM: https://www.docker.com/blog/speed-boost-achievement-unlocked-on-docker-desktop-4-6-for-mac/

This fix has been released in Docker for Mac 4.6 and macOS 12.2 or above is required to enable this experimental feature. I tried this myself with Docker for Mac 4.8 and it seems to have resolved the performance problem. As a result, the Apigee Emulator AMD64 based container image starts on M1 Macbooks successfully.

Still, I think it is better if a newer version of Apigee Emulator container image can be released by adding support for ARM64 CPU architecture. Thanks!