Possibility to run Fabio on Apple M1
Closed this issue · 3 comments
Hi,
Is it possible to provide Fabio version that is compatible with Apple M1 arm64 architecture ?
I was checking on Docker Hub and I see that currently https://hub.docker.com/r/softwaremill/fablo image supports only linux/amd64 architecture.
Regards
Hi @Lucas1983 Fablo actually works on Apple M1 (I have one and use Fablo on daily basis). Did you try? Did you have some issues with that?
Actually it works, but while startup I constantly getting info about architecture incompatibility e.g. The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested.
I was wondering if this has any impact ob Fabio performance ?
I have manually built the Fablo containers for ARM by following the instructions on this webpage, which details how to build Fabric: https://www.polarsparc.com/xhtml/Hyperledger-ARM-Build.html. To build Fabric, I simply execute the command make docker GO_TAGS=noplugin. I am using the 2.4.9 tag and run it with the postGenerate hook workaround mentioned here: #372 (comment)
Although I was unable to build Fabric-CA, I have successfully run the official version of Fabric-CA 1.5.6, which supports ARM containers.
Here is my postGenerate hook:
"hooks": { "postGenerate": "perl -i -pe 's/MaxMessageCount: 10/MaxMessageCount: 1/g' \"./fablo-target/fabric-config/configtx.yaml\"; perl -i -pe 's/_VERSION=2.4.3/_VERSION=2.4.9/g' ./fablo-target/fabric-docker/.env; perl -i -pe 's/FABRIC_CA_VERSION=1.5.0/FABRIC_CA_VERSION=1.5.6/g' ./fablo-target/fabric-docker/.env;" }
Running with native ARM containers has resulted in a noticeable improvement in performance, making it a worthwhile endeavor.